what's a debugger? XD sorry, I'm still a beginner..
I got the output that I wanted.. which is "9"..
but my question is, how did it came to this output?
is it because "012345678" are 9 digits so i=9?
No. Well, not exactly. You are incrementing by one each time. when you get to 8 it is still passing, so it increments again to 9. When it tests again it fails and comes out of the loop. So at that point i=9.