The ratio of the girls to the total number of students in class is 47 how many students are girls in the class has 21 students and all

You can cross multiply to get 4 * 21 = 7x
84 = 7x; divide both sides by 7
12 = x so the number 12 will go in the blank (12 girls)