Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options
 
PerlMonks  

Re^4: <STDIN> not initializing $_

by stiller (Friar)
on May 01, 2008 at 05:39 UTC ( #683860=note: print w/ replies, xml ) Need Help??


in reply to Re^3: <STDIN> not initializing $_
in thread <STDIN> not initializing $_

An extra edge case:
perl -le'while($a = 0){print "$a ok\n"; last }' # perl -le'while($a = 1){print "$a ok\n"; last }' # prints 1 ok
But the "implicit test for defined" is built into the while( ) by language design, there is no extra magic about that in any context?

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others musing on the Monastery: (3)
As of 2016-07-30 05:26 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    What is your favorite alternate name for a (specific) keyboard key?


















    Results (265 votes). Check out past polls.