gam3 has asked for the wisdom of the Perl Monks concerning the following question:
where alice, bob, charlie and david are apropriate subroutines Doing a simple transformation towhile (alice) { charlie; last if bob; david; }
does not compile, since the do does not know anything about the while. There are certainly lots of ways to fix this, but I thought that there might be an eligant approach that I have not though of.do { charlie; last if bob; david; } while (alice);
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: last in a do while loop
by Hofmator (Curate) on Nov 03, 2006 at 13:23 UTC | |
by ikegami (Patriarch) on Nov 03, 2006 at 15:48 UTC | |
by Jenda (Abbot) on Nov 03, 2006 at 20:50 UTC | |
by ikegami (Patriarch) on Nov 03, 2006 at 21:38 UTC | |
by Jenda (Abbot) on Nov 04, 2006 at 00:08 UTC | |
by JimmyDa (Initiate) on Jan 23, 2008 at 16:32 UTC | |
| |
|
Re: last in a do while loop
by davorg (Chancellor) on Nov 03, 2006 at 13:28 UTC | |
by Hofmator (Curate) on Nov 03, 2006 at 13:39 UTC | |
by davorg (Chancellor) on Nov 03, 2006 at 13:48 UTC |