0

For some reason I get "none" when I ask for input from the user, it doesn't matter if it's in a function.

age = input(print("whats your age: "))
print(f"Your age is {age}")

output: whats your age: None50 Your age is 50


Ignas
  • 13
  • 1

1 Answers1

0

input already prints its param. print returns None. that's why input prints None.

try this:

age = input("whats your age: ")
print(f"Your age is {age}")
Adam.Er8
  • 12,675
  • 3
  • 26
  • 38