Hi!

Is there a simpler/fster way to check if a value
has int or float type (i.e. is a "real number") than:

v=<some numeric value>
if isinstance(v, int) or isinstance(v, float):
     <block>

(v must not be complex)

Regards,
Gregor




-- 
Gregor Lingl
Reisnerstrasse 3/19
A-1030 Wien

Telefon: +43 1 713 33 98
Mobil:   +43 664 140 35 27

Website: python4kids.net
_______________________________________________
Tutor maillist  -  Tutor@python.org
http://mail.python.org/mailman/listinfo/tutor

Reply via email to