Beefy Boxes and Bandwidth Generously Provided by pair Networks
There's more than one way to do things
 
PerlMonks  

Re: backwards if and while looping

by !1 (Hermit)
on Oct 01, 2004 at 22:16 UTC ( #395769=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    $a = $b unless $error;
    
  2. or download this
    while ($a < $b) if not $error
     { $a++; }
    
  3. or download this
    $a++ while ! $error && $a < $b;
    
    ...
    }
    
    do { $a++ while $a < $b } if ! $error;
    
  4. or download this
    $a++ while not $error || $a >= $b;
    
    $a = $b unless $error or $a >= $b;
    

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://395769]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others chanting in the Monastery: (2)
As of 2021-10-18 22:33 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    My first memorable Perl project was:







    Results (76 votes). Check out past polls.

    Notices?