out putmy ($i , $j); $i = 1; $j = $i - 1; print "before sub value of i=$i\n"; sub abc { $i = $i+1; print "inside sub $i\n"; $j = $j+1; } abc(); print "after sub $i\n";
prints the edited value.before sub value of i=1 inside sub 2 after sub 2
In reply to Re: variable declaration
by ansh batra
in thread variable declaration
by Priti24
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |