2
Answers

Variable defined within "for" loop can't be called outside

Ameer Wadi

Ameer Wadi

6y
207
1
Hi everyone;
 
I'm just a beginner with C#. When I define a variable inside for loop, it can't be recognized afterwards, as it has been NOT defined within the code. Following picture shows the problem. (Code should work properly but its NOT)
 
 
Thanks in advance,
Answers (2)