That rejects anything with a leading zero (hence "0"), and anything greater that 255.while (<>) { chomp; my $result = ( /^([1-9]\d*)$/ and $1 < 256 ) ? "matched" : "did no +t match"; $_ .= " $result\n"; print; }
In reply to Re: Is this a bug in perl regex engine or in my brain?
by graff
in thread Is this a bug in perl regex engine or in my brain?
by nikmit
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |