Help for this page

Select Code to Download


  1. or download this
    #!/usr/bin/perl
    use strict;
    use warnings;
    ...
            say "no match on $string";
        }
    }
    
  2. or download this
    (?-xism:foo\d+) when string is "foo17"
    (?-xism:bar\S+?) when string is "barABC"
    (?-xism:bar\S+?) when string is "nomatch"
    
  3. or download this
    hashbang, strict, warn, etc...
    
    my $regex1 = qr/foo\d+/;
    ...
            say "no match on $string";
        }
    }
    
  4. or download this
    matched part of "foo17" is foo17 when  regex is "(?-xism:foo\d+)"
    matched part of "barABC" is barA when regex is "(?-xism:bar\S+?)"
    no match on this-has-no-match