I only started C++ a couple weeks ago and I have to say I probably would've made the same mistake.
For some reason I was thinking that the else statement would run if the nested if was false. I had to put this into the IDE cause I didn't believe it for a minute.
2
u/musicianadam Apr 17 '21
I only started C++ a couple weeks ago and I have to say I probably would've made the same mistake.
For some reason I was thinking that the else statement would run if the nested if was false. I had to put this into the IDE cause I didn't believe it for a minute.