in reply to Re^3: dependable way to test for a float
in thread dependable way to test for a float
Prints this:my $var = 23123412341234.01222222; print "var=$var\n"; if(int($var) != $var){ print "is a float\n"; } else{ print "not a float\n"; }
The test is always working for me, so that is a good confirmation. However, I was wondering why it prints the integer before the int() function touches the variable?var=23123412341234 is a float
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^5: dependable way to test for a float
by Roy Johnson (Monsignor) on May 06, 2005 at 19:12 UTC |