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 Meet Python Using Input

In using_input.py it won't let me move on and keeps switching from the color mauve to red

using_input.py
favorite_color=input("what is your favorite color?")
favorite_color='Mauve'
print('The color',favorite_color,'is a great color!')

7 Answers

Try not actually setting the color to mauve or red, I think it was just an example. So, just run your first and last line of code.

I did exactly that but it wont execute

It worked thanks!

No problem!!

Hmm it worked for me.Can I see your code?

favorite_color = input("what is your favorite color?" ) print("The color ,favorite_color is a great color!")

i cant seem to upload a screenshot i have not any of those options

Have you tried doing the code but with just one quotation marks instead of 2 so it should look like input('what is your favorite color?') print('the color'favorite_color,'is a great color!')

It finally worked ! THANK YOU SOO MUCH !!

Glad to help!

When I enter "Red" as my favorite color variable it says, "'Mauve' not found in 'The color Red is a great color!' : Make sure you are printing out 'The color Mauve is a great color!' (Mauve is my favorite that I inputted)".

Then when I switch the variable to "Mauve" it says "Hmm...I answered the prompt with 'Red' but that's not what was in the variable favorite_color"

Am I losing my mind??

I figured out that if I made a line that said print('The color', favorite_color, 'is a great color!') with the variable favorite_color = 'Red' Then a fourth line that said print('The color', 'Mauve', is a great color!') It worked! just dupe it by doing both lines with the variable as red and one without the variable, but just 'Mauve'