Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re^3: Scalar Value Not Available To Subroutine

by BrowserUk (Pope)
on Dec 20, 2012 at 18:04 UTC ( #1009772=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    my $i; 
    for $i ( 1..10 ){ 
    ...
    }; 
    print $i };;
    Use of uninitialized value $i in print at (eval 9) line 1, <STDIN> lin
    +e 1.
    
  2. or download this
    my $i;
    for $i ( 1 .. $N ) {
    ...
    }
    ## Here we have no way of knowing if we took an early exit;
    ## thus necessitating additional, unnecessary complexity to retain or 
    +discover that.
    

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1009772]
help
Chatterbox?
[choroba]: erix Yes, but in the later concert :-)

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (7)
As of 2017-12-12 14:59 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    What programming language do you hate the most?




















    Results (335 votes). Check out past polls.

    Notices?