Why isn't my calculator code working?
Ok I've revised it a little but it seems that it doesn't register c = input() therefore not continuing the rest of the code. def calc(): print("Press 1 for addition") print("Press 2 for subtraction") print("Press 3 for multiplication") print("Press 4 for division") c = input() if c == 1: print("Enter a number") x = input() print("Enter another number") y = input() return x + y elif c == 2: print("Enter a number") x = input() print("Enter another number") y = input() return x - y elif c == 3: print("Enter a number") x = input() print("Enter another number") y = input() return x * y elif c == 4: print("Enter a number") x = input() print("Enter another number") y = input() return x / y calc()