Quotes help make search much faster. Example: "Practice Makes Perfect"
Friday, November 30, 2012
Codecademy: is_int
#sample solution
def is_int(x): for c in str(x): if c == ".": numlist = str(x).split(".") #print numlist if int(numlist[1])>0: #print numlist[1] return False else: return True else: if isinstance(x, int): return True
No comments:
Post a Comment