def oddEven(x): if str(abs(x)).find('0') == -1: if str(abs(x)).find('2') == -1: if str(abs(x)).find('4') == -1: if str(abs(x)).find('6') == -1: if str(abs(x)).find('8') == -1: return 1 else: return 0 else: return 0 else: return 0 else: return 0 else: return 0
def oddEven(n):return not str(n)[-1] in "02468"- def oddEven(x):
- if str(abs(x)).find('0') == -1:
- if str(abs(x)).find('2') == -1:
- if str(abs(x)).find('4') == -1:
- if str(abs(x)).find('6') == -1:
- if str(abs(x)).find('8') == -1:
- return 1
- else: return 0
- else: return 0
- else: return 0
- else: return 0
- else: return 0