Let`s assume the total number of boys in the class as `B` and the total number of students in the class as `S`.
According to the given information:
1. 18 boys are over 160 cm tall, which constitutes three-fourths of the boys. So, (3/4)B = 18.
Multiplying both sides by (4/3) gives B = 24.
2. The total number of boys is two-thirds of the total number of students. So, B = (2/3)S.
Substituting the value of B as 24, we get 24 = (2/3)S.
Multiplying both sides by (3/2) gives S = 36.
Now, to find the number of girls, we subtract the number of boys from the total number of students:
Number of girls = S - B = 36 - 24 = 12.
Therefore, the number of girls in the class is 12.