Help for this page

Select Code to Download


  1. or download this
        # Expand ranges of numbers so [21-25] becomes  (21|22|23|24|25)
        # Ugh!
    ...
            foreach (@i) {
                if ( /\[(\d+)-(\d+)\]/ ) {
                $_ = "(" . join("|", ($1..$2)) . ")"