Help for this page

Select Code to Download


  1. or download this
    unshift @ARGV, $rfile;
    while( <> ) {
      # ....
    }
    
  2. or download this
    use Tie::File;
    tie my @array, 'Tie::File', $rfile or die;
    
  3. or download this
    #!/usr/bin/perl -p
    BEGIN{ 
        $rfile = 'myfile.txt';
        unshift @ARGV, $rfile;
    }