Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re: hex-only regex

by davidrw (Prior)
on Jan 17, 2007 at 16:55 UTC ( [id://595104]=note: print w/replies, xml ) Need Help??


in reply to hex-only regex

TMTOWTDI -- Regexp::Common::number
use Regexp::Common qw /number/; while(<DATA>){ chomp; print /\A$RE{num}{hex}\z/ ? 'YES' : 'NO '; print " $_\n"; } __DATA__ 12345 abc1234 foo123 ab123CD

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://595104]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others musing on the Monastery: (6)
As of 2024-04-23 20:04 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found