try: num = float(raw_input("\nEnter a number: "))except(ValueError), e: print "Not a number! Or as Python would say:\n", e