A group consisting 10 children and adults went to a movie theater. Children's tickets cost $5 each and adults' tickets cost $8 each, and the total cost for 10 people was $62. How many children were in the group?