Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re: Large file processed line by line

by btrott (Parson)
on Jun 19, 2001 at 05:02 UTC ( #89533=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
        open FH, "foo" or die "Can't open foo: $!";
        while (<FH>) {
            ## current line is in $_, process it
        }
        close FH or warn "Error closing foo: $!";
    
  2. or download this
        while (<>) {
            ## line is in $_
        }
    
  3. or download this
        $ process.pl foo.txt bar.txt baz.txt
    

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others perusing the Monastery: (4)
As of 2023-03-22 00:37 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Which type of climate do you prefer to live in?






    Results (60 votes). Check out past polls.

    Notices?