dbp gave you the faq supported answer and it can be found in
perlfaq4 under
"How do I determine whether a scalar is a number/whole/integer/float?". Then check the
Floating-point Arithmetic section of
perlop as to why your comparison
of a float is going to lead you down a subtle path of bugs.
-derby