Help for this page

Select Code to Download


  1. or download this
    print do_stuff();
    
  2. or download this
    
    use strict;
    ...
    $_ = 'hello world goodbye';
    
    s/$target/print $should_replace{$target} ? "$repl " : "[$repl] "/ex;
    
  3. or download this
    use strict;
    use warnings;
    ...
        my $output = exists $should_replace{$target} ? "$repl " : "[$repl]
    + ";
        say $output;
    }
    
  4. or download this
    use strict;
    use warnings;
    ...
    
    --output:--
    [Hello]