I was reading this book and it said : Variables declared in a scope aren't visible outside it.
It also said : Scopes are declared by 2 curly braces - like a block of code.
So, if I had a situation like this :
for(_statement1_)
{
int var;
/*code*/
}
cout << var << " number of rockets left.\n";
Would the value printed be the same as the value of the var
declared in the loop?
Thank you