Help for this page

Select Code to Download


  1. or download this
    # prints 'j'
    "japhy" =~ m{ (.) (?{ print $1 }) }x;
    ...
    # prints nothing (undef, specifically)
    $rx = qr{ (.) (??{ print $1 }) }x;
    "japhy" =~ m{ (??{ $rx }) }x;
    
  2. or download this
    use Data::Dumper;
    $Data::Dumper::Indent = 1;
    ...
      my $alt = pop @r;
      [ @r, { ALT => [ @{ $alt->{ALT} }, $w->{WORD} ] } ];
    }