Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Python Python Basics (Retired) Things That Count Basic Numbers

NameError: name input not defined

input_int = imput("How many times should I repeat it? ")
NameError: name 'imput' is not defined


imput_string = input("What string do you want to use? ") input_int = imput("How many times should I repeat it? ")

Code is exactly the same as it is in the video, yet I still get this error, I tried using raw_input instead but I got the same error.

3 Answers

Sean T. Unwin
Sean T. Unwin
28,690 Points

Careful about typos. 'imput' is not the same as 'input'. :wink:

Figured that out! LMAO. THANKS!

i've got an error too

my script :

input_string = input("What string do you want to use? ") input_int = input("How many times should I repeat it? ") print(input_string+int(input_int))

Error when i input Hello

Traceback (most recent call last): File "C:\Users\Hasny\Documents\path\mul.py", line 1, in <module> input_string = input("What string do you want to use? ") File "<string>", line 1, in <module> NameError: name 'Hello' is not defined