C
cody
why foreach does always have to declare a new variable?
I have to write
foreach (int n in array){}
but Iam not allowed to write:
int n=0;
foreach (n in array){}
what is the reasoning behind that?
I have to write
foreach (int n in array){}
but Iam not allowed to write:
int n=0;
foreach (n in array){}
what is the reasoning behind that?