+ 1

Write the program that will show odd or even no.

18th Mar 2017, 12:32 PM
Pushkar Khadase
Pushkar Khadase - avatar
4 Respostas
+ 8
print(int(input()) % 2 == 0) True if even False if odd
18th Mar 2017, 12:51 PM
Kuba Siekierzyński
Kuba Siekierzyński - avatar
+ 8
Check out the upgraded version below ;) print('even' if int(input())%2==0 else 'odd')
18th Mar 2017, 9:38 PM
Kuba Siekierzyński
Kuba Siekierzyński - avatar
+ 1
ty brow
18th Mar 2017, 2:13 PM
Pushkar Khadase
Pushkar Khadase - avatar
+ 1
no branching print ['Even', 'Odd'][input() & 1]
19th Mar 2017, 5:03 AM
Suvaditya
Suvaditya - avatar