There's more than one way to do things | |
PerlMonks |
Re: Regular expression for hexadecimal numberby radiantmatrix (Parson) |
on Jul 30, 2007 at 15:18 UTC ( [id://629593]=note: print w/replies, xml ) | Need Help?? |
I'm curious about your actual requirement, because I'm not sure a regex is the way you want to go. If you have a hexadecimal value already, working with it as a number is pretty easy: using a regex is working with it as a string. Consider:
All this requires is use of the hex function.
<–radiant.matrix–>
Ramblings and references The Code that can be seen is not the true Code I haven't found a problem yet that can't be solved by a well-placed trebuchet
In Section
Seekers of Perl Wisdom
|
|