+ 3
Because a is declared inside the loop, but the rest is not inside the loop. a does not exist outside the loop. You might recall that if you don't use {} with a for loop then only 1 expression is part of the loop. I recommend that you use indentation. There are some more issues, but I'm sure you can find those. :)
25th Jan 2019, 4:15 PM
Dennis
Dennis - avatar