in reply to Regexp for alphabetical order match within the string
my $str = join '', map "$_*", "a".."z"; my $re = qr/^$str$/; print "Matches\n" if "abc" =~ $re; print "Doesn't match\n" unless "zbc" =~ $re;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Regexp for alphabetical order match within the string
by CountZero (Bishop) on Oct 30, 2003 at 19:30 UTC |