Help for this page

Select Code to Download


  1. or download this
    my @lines;
    foreach my $file(@files) {
        open(IN, "< $file") or die "Can't open $file: $!";
    ...
        close IN;
    }
    # Now do whatever you want with @lines
    
  2. or download this
        while(my $line = <IN>) {
            #Do whatever processing you want with $line
        }