in reply to Re: A way to avoid repeated conditional loops
in thread A way to avoid repeated conditional loops
Update: And I just noticed the part in the OP where it says "without a flag variable"...oh, well...my $got_alpha; while (<FILE>) { unless ($got_alpha) { if (/alpha/) { #...alpha code $got_alpha++; next; } } # ...more code }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: A way to avoid repeated conditional loops
by AR (Friar) on Aug 24, 2011 at 17:04 UTC |