Beefy Boxes and Bandwidth Generously Provided by pair Networks
laziness, impatience, and hubris
 
PerlMonks  

Re: How to print a file line by line?

by Anonymous Monk
on Jul 04, 2000 at 06:44 UTC ( [id://20977]=note: print w/replies, xml ) Need Help??


in reply to How to print a file line by line?

print "$_<br>\n", while <IN>;

You could also add a little $\ and local magic:

{ local $\ = "<br>\n"; print while <IN>; }

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (3)
As of 2024-04-25 06:48 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found