I'm going to try the strategy of "narrow it down slowly."
Let's start with how many perfect squares there are less than 1000. We have
0^2 = 0
1^2 = 1
2^2 = 4
3^2 = 9
...
30^2 = 900
31^2 = 961
32^2 = 1024
This means there are 0...31 so 32 perfect squares less than 1000.
Three times an odd integer... this is tricky. If you think about it, if n is divisible by three, then n must have a factor of 9 in it (why?), so
must have a factor of three! Boom, now we just have to count how many odd numbers from 0...31 are divisible by three. The first one is 1(3), the second is 3(3), the third is 5(3), the fourth is 7(3), and the fifth is 9(3). This means there are five such numbers.