0

How to give null value to a variable?

x=int(input()) y=int(input()) try: z=input() finally : userList = [x,y,z] sum = 0 for num in userList: a=int(num) if(a%2 == 0): sum += int(num) print(sum)

9th Apr 2020, 12:41 PM
madhan mallisetty
madhan mallisetty - avatar
1 Odpowiedź
+ 2
Z=input()or 0
9th Apr 2020, 12:47 PM
Oma Falk
Oma Falk - avatar