Help for this page

Select Code to Download


  1. or download this
    # Perl lets you use a glob wherever you would use a filehandle, so glo
    +bs are often used to pass filehandles to a subroutine:
    
    ...
      open(HANDLE, $filename) or die;
      mysub(*HANDLE);
    
  2. or download this
      sub mysub { my $fh = shift; while (<$fh>) { ... } }