Help for this page

Select Code to Download


  1. or download this
    # made-up example with actual issue
    $ perl -le 'my $str = q{zxcv}; if ( $str -~ m/some pattern/i ) { print
    + $str; }'
    zxcv
    
  2. or download this
    # made-up example with actual issue, with strict and warnings
    $ perl -Mstrict -Mwarnings -le 'my $str = q{zxcv}; if ( $str -~ m/some
    + pattern/i ) { print $str; }'
    Use of uninitialized value $_ in pattern match (m//) at -e line 1.
    Argument "zxcv" isn't numeric in subtraction (-) at -e line 1.
    zxcv