How many time do you think this
for (int i = 0; i > 40; i++)
will loop?
The
for
little bit more in detail:
a.) We start here: i= 0;
b.) We proceed as long condition is true: Do it as long i > 40; ..... think about this....
Is i ever > 40? No, because you start with it at zero and therefore nothing will happen ;)
Wild guess, maybe you mean this:
for (int i = 0; i < 40; i++)