What you can say about 12th, 18th and the 21st child, depends if these numbers are multiples of 4 (every 4th child is wearing spectacles), 3 (every 3rd child is a girl) and 2 (every 2nd child is wearing a white shirt).
If a numer is multiple of another one, then the quotient between them is an integer number.
for 12th:
12/4 = 3
12/3 = 4
12/2 = 6
12 is multiple of 3, 4 and 6.
Then, 12th child is wearing spectacles, a white shirt and is a girl.
for 18th:
18/4 = 4.5
18/3 = 6
18/2 = 9
18 is multiple of 3 and 2.
Then, 18th child is a girl and is weraing a white shirt
for 21th:
21/4 = 5.25
21/3 = 7
21/2 = 11.5
21 is multiple of 3.
THen, 21st child is a girl.