Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

Answer: How do I match a number range?

by Anonymous Monk
on Mar 25, 2001 at 08:29 UTC ( #66952=categorized answer: print w/replies, xml ) Need Help??

Q&A > regular expressions > How do I match a number range? - Answer contributed by Anonymous Monk

It's probably best to use numeric comparisons, but if you absolutely need a regexp, you can use
/^5(2(7[89]|[89]\d)|3([0-8]\d|9[01]))$/

Log In?
Username:
Password:

What's my password?
Create A New User
Chatterbox?
[marto]: even the YouTubes?

How do I use this? | Other CB clients
Other Users?
Others musing on the Monastery: (7)
As of 2017-06-27 15:50 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    How many monitors do you use while coding?















    Results (610 votes). Check out past polls.