Title |
Test
Find
Pattern Title
|
Expression |
^[-+]?[1-9]\d*\.?[0]*$ |
Description |
This will check if a number is an integer. Positive integers are all the whole numbers greater than zero: 1, 2, 3, 4, 5, ... . Negative integers are all the opposites of whole numbers: -1, -2, -3,-4, -5, ... . Zero is not a whole number with either a positive or negative value, and is not an interger. Null or Empty values are not intergers. |
Matches |
10 | -10 | +10.00 |
Non-Matches |
0 | -10.50 | 10.50 |
Author |
Rating:
Not yet rated.
Chuck Scholton
|
Source |
|
Your Rating |
|
Title: Zero is an integer: Provided link
Name: Mark
Date: 7/28/2006 7:34:09 PM
Comment:
This didn't make it through in the URL field:
http://mathworld.wolfram.com/Integer.html
Title: 0 is an integer
Name: Mark
Date: 7/28/2006 7:33:19 PM
Comment:
0 is an integer. Check out the provided link.
Title: Now Corrected
Name: Chuck Scholton
Date: 8/27/2003 4:49:16 PM
Comment:
No Longer will match 200!00 patterns. There was missing a \ before the . in the regex. Retested and the current expression is updated.
Title: Not correct
Name: Hardy
Date: 8/27/2003 4:23:29 PM
Comment:
try to check "200!00", pattern says matching...