Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
# sample matches: $3,023,123.34 / 9,876,453 / 123456.78 # sample non-matches: 4,33,234.34 / $1.234 / abc #"^\$?([0-9]{1,3},([0-9]{3},)*[0-9]{3}|[0-9]+)(.[0-9][0-9] +)?$" #"^\$?([0-9]{1,3},([0-9]{3},)*[0-9]{3}|[0-9]+)(.[0-9][0-9] +)?$" if ($payment=~/^\$?([0-9]{1,3},([0-9]{3},)*[0-9]{3}|[0-9] ++)(.[0-9][0-9])?$/g) { print "*match*$payment*match*<br>"; }else{print "No match";}
|
|---|