nmerriweather has asked for the wisdom of the Perl Monks concerning the following question:
vssub function{ my ($a,$b,$c,$d); $a = 1; $b = 2; $c = 3; $d = 4; }
Is one more appropriate than the other? Does it matter? Should I declare local variables early on?sub function{ my $a = 1; my $b = 2; my $c = 3; my $d = 4; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Question on use of 'my'
by Zaxo (Archbishop) on May 14, 2004 at 00:38 UTC | |
by Fletch (Bishop) on May 14, 2004 at 03:26 UTC | |
|
Re: Question on use of 'my'
by NetWallah (Canon) on May 14, 2004 at 00:32 UTC | |
by nmerriweather (Friar) on May 14, 2004 at 00:40 UTC | |
by davido (Cardinal) on May 14, 2004 at 01:12 UTC | |
|
Re: Question on use of 'my'
by duff (Parson) on May 14, 2004 at 13:59 UTC |