Help for this page

Select Code to Download


  1. or download this
    local $_ = 'foo';
    say 'Start' if /\G foo/gcx;
    say 'Mid'   if /\G .*/gcx;
    say 'End'   if /\G \z/gcx;
    
  2. or download this
    Start
    Mid
    
  3. or download this
    say 'Mid' if /\G .+/gcx;
    
  4. or download this
    Start
    Mid
    End
    
  5. or download this
    perl -E 'local $_ = "foo\n"; say "Start" if /\G foo/gcx; say "Mid" if 
    +/\G .*/gcx; say "End" if /\G (?=\n)/gcx'