in reply to Re^2: how to loop
in thread how to loop
I would have expected that either (a) the value assigned to $mode would depend on @ARGV (or %ENV, or some other external input), or (b) there would be something inside the loop that could change the value of $mode, or else (c) each time you edit the script to change its behavior, rather than editing a variable assignment, you would just edit the loop condition -- e.g. do {...} while(0); vs. do {...} while(1);, or something to that effect. (Note that the former "do" block will execute exactly once, whereas the block in while(0){...} never executes.)
As it is, I tend to share muba's puzzlement.
(updated to fix spelling)
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: how to loop
by rsiedl (Friar) on Feb 21, 2007 at 07:57 UTC | |
by graff (Chancellor) on Feb 21, 2007 at 08:13 UTC |