Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re^3: eof not recognised when applying diamond operator to invocation arguments?

by Anonyrnous Monk (Hermit)
on Jan 12, 2011 at 16:53 UTC ( #881945=note: print w/replies, xml ) Need Help??


in reply to Re^2: eof not recognised when applying diamond operator to invocation arguments?
in thread eof not recognised when applying diamond operator to invocation arguments?

Why is the code I posted not behaving equivalently to ...

because in your original code the eof is tested only once before everything is being read and output.  In the second case, it's tested for every line, so it has a chance to detect the end-of-file conditions.

  • Comment on Re^3: eof not recognised when applying diamond operator to invocation arguments?

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://881945]
help
Chatterbox?
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (8)
As of 2017-12-18 09:28 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    What programming language do you hate the most?




















    Results (475 votes). Check out past polls.

    Notices?