Help for this page

Select Code to Download


  1. or download this
    #!/usr/bin/env perl
    
    ...
    print "Original string: $str\n";
    print "Parts separated by some dash:\n";
    print "$_\n" for split $re, $str;
    
  2. or download this
    Original string: a-b–c—d
    Parts separated by some dash:
    ...
    b
    c
    d
    
  3. or download this
    $ ./pm_11137036_re_alt_dashes.pl | cat -vet
    Original string: a-bM-bM-^@M-^ScM-bM-^@M-^Td$
    ...
    b$
    c$
    d$