The remaining boys: girls = 16: 15.
Each serving: 3/( 16- 15)=3 (person)
The remaining boys: 3x 16=48 (person)
The remaining girls: 3x 15=45 (person)
Male: 48/( 1- 1/9)=54 (person)
Female student: 45+3=48 (person)
Solution 2:
The remaining boys are 16, so the original boys are16/(1-kloc-0//9) =18.
Each copy: (102-3)/(18+15) = 3 (person)
Original boy: 3x 18=54 (person)
Original female student: 102-54=48 (person)