Apply law of exponents, when bases are same for exponents in multiplication, add the exponents. When a base with an exponent has a whole exponent, then multiply the two exponents.
Well, ratios are basically fractions. There are 12 boys, so the ratio is 12/25. Since 25 - 12 is 13, there are thirteen girls, so the ratio of girls to student is 13/25.