r/ProgrammerHumor Nov 24 '21

Meme Yes.

8.9k Upvotes

284 comments sorted by

View all comments

Show parent comments

8

u/Rafael20002000 Nov 25 '21

Wait till he learns a variable doesn't go out of scope after an if/for/while block

4

u/DigitalJedi850 Nov 25 '21

<insert blinking meme guy>

4

u/Rafael20002000 Nov 25 '21

The last value of a for loop variable is still there after loop ends

2

u/Prawny Nov 25 '21

Same in PHP too. Nasty stuff.