@Marta Pa,
Let K be the number of cars (K<1000)
and K is divisible by 9
lets look at numbers divisible by 9
0*9=0
1*9=9
2*9=18
3*9=27
4*9=36
5*9=45
6*9=54
7*9=63
8*9=72
9*9=81
From this list pick numbers that are divisible by 5 with remainders of 1
these are 36 (7R1) and 81(16R1)
of these two numbers 36 is evenly divisible by 4 (12R0)
but 81 has a remainder of 1 (81/4)=20R1
So the lowest possible number is 81
Now look for the rest
A number that is evenly divisible by 4, 5 & 9 is 180 (4*5*9=180)
So any number that is a additive multiple of 180to 81 has this same property.
(K=81+n*180 where n is an integer)
If the total number of cars is less thas 1000 then the maximim n is 5
and all solutions are
n=0, K=81
n=1 , K=261
n=2 , K=441
n=3 , K=621
n=4 , K=801
n=5 , K=981
Rap