Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

Re: Stupid regex question - numerics

by ungalnanban (Pilgrim)
on Mar 01, 2010 at 12:33 UTC ( #825898=note: print w/ replies, xml ) Need Help??


in reply to Stupid regex question - numerics

See the following code for matching your pattern.

if ( $long =~ /^([\-\+]?\d+[\.]?\d*)$/ ) { print "match\n"; }
Thanks.


Comment on Re: Stupid regex question - numerics
Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (8)
As of 2015-07-28 05:49 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (252 votes), past polls