Hi,
I have execute following code.
#!/usr/bin/perl foo(); bar(); for (1..3) { my $x; sub foo { print ++$x } sub bar { print ++$x } print ++$x; }
Result: 12311
Could you please tell me how the result is coming like this??
Thanks,
Shine.
In reply to Trying to understand closures by shine22vn
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |