Your regex only catches positive integers, which may be okay -- but it's certainly not all valid numbers. Consider negative integers, rationals, and numbers in scientific notation, for exammple.
In reply to Re^2: need idiom - compare a number to a string
by chromatic
in thread need idiom - compare a number to a string
by nmerriweather
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |