tenya has asked for the wisdom of the Perl Monks concerning the following question:
use strict; use diagnostics; my @aa = ([1,2],[3,4]); for (@aa) { for (1..3) { print $_; last; } print "forfor=$_\n"; } my @bb = ([5,6],[7,8]); for (@bb) { while (<STDIN>) { print "while=$_\n"; last; } print "forwhile=$_\n"; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: While but not for clobbers $_
by chromatic (Archbishop) on Apr 15, 2003 at 03:21 UTC | |
|
Re: While but not for clobbers $_
by BrowserUk (Patriarch) on Apr 15, 2003 at 03:33 UTC | |
by Nkuvu (Priest) on Apr 15, 2003 at 06:59 UTC | |
by BrowserUk (Patriarch) on Apr 15, 2003 at 11:16 UTC |