How can I read inputs as numbers?
Solution Since Python 3, input returns a string which you have to explicitly convert to ints, with int, like this x = int(input(“Enter a number: “)) y = int(input(“Enter a number: “)) You can accept numbers of any base and convert them directly to base-10 with the int function, like this >>> data = int(input(“Enter … Read more