No inner my $i means the outer one is everywhere available.
These are universal rules for lexical variables in almost any language!
Have a look at the scoping-article I linked.
Cheers Rolf
( addicted to the Perl Programming Language)
In reply to Re^3: scoping inside the loop
by LanX
in thread scoping inside the loop
by vyeddula
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |