Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling
 
PerlMonks  

Re: Re: Re: For loop problem

by japhy (Canon)
on Jun 03, 2001 at 23:19 UTC ( #85357=note: print w/ replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    $start = $a;
    $end = ++$a;
    for ($_ = $start; $_ <= $end; $_++) { ... }
    
  2. or download this
    for (++$x .. $x++ . $x) { ... }
    # starting at ++$x
    # ending at $x++ . $x
    # THE END HAS MODIFIED THE START
    
  3. or download this
    print ++$x, ++$x, ++$x;  # 333
    
  4. or download this
    $x = 3;
    print ++$x/$x--;  # 3/4 => 0.75
    
  5. or download this
    for (++$x .. $x++ . $x--) { ... }
    # or
    for (++$....$.++.$.--) { ... }
    

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others wandering the Monastery: (8)
As of 2015-07-05 19:59 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (67 votes), past polls