Help for this page

Select Code to Download


  1. or download this
    $regex = qr/(?{print "Hey!";})/x;
    $string = "some word";
    
    $string =~ /some($regex)/;
    
  2. or download this
         qr/STRING/imosx
                 This operator quotes (and possibly compiles) its
    ...
                 is attempted.  (Perl has many other internal
                 optimizations, but none would be triggered in the
                 above example if we did not use qr() operator.)
    
  3. or download this
    # Under Construction