#try to avoid input function a = int(input()) b = int(input()) c = int(input()) print("1.Total","2.Average","3.Percentage") d = int(input()) if d == 1: print(a+b+c) elif d == 2: print((a+b+c)/3) elif d == 3: print(((a+b+c)/3)*100) else: print("invalid input")
Click the run button. Try to avoid input() function.