Help for this page

Select Code to Download


  1. or download this
    while (<>) {
       if (/.../) {
          push @matches, ...;
       }
    }
    
  2. or download this
    while (<>) {
       while (/.../g) {
          push @matches, ...;
       }
    }
    
  3. or download this
    my $file; { local $/; $file = <>; }   # Slurp file.
    while ($file =~ /.../g) {
       push @matches, ...;
    }