Help for this page

Select Code to Download


  1. or download this
    #!usr/bin/perl -w
    use strict;
    ...
    my @strings = glob "{abc}{0,p,z}"; #to enumerate the combinations
    
    print "@strings\n"; #abc0 abcp abcz
    
  2. or download this
    my $prefix = 'abc';
    my $endingLetters = '0pz';
    if (/$prefix[$endingLetters]/){...}