Boys account for 2/3 of all students.
Girls account for 1/3 of all students.
The second category:
Boys account for 2/5 of all students.
Girls account for three fifths of all students.
The third category:
Boys account for 3/ 10 of all students.
Girls account for 7/ 10 of all students.
Your question is not easy to understand, so I will write two understandings:
The ratio of boys to girls is (2/3+2/5+3/10): (1/3+3/5+7/10).
Finishing: 4 1: 49
The ratio of boys in the three classes is 20: 12: 9.
The ratio of girls in three classes: 10: 18: 2 1.
I hope my answer is helpful to you. Take it, O(∩_∩)O!