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 trialMiles Almas
109 PointsPython Basics, Challenge 2, input function
I've been on this second question of the quiz for 4 days. I've inputed multiple variations and looked up multiple answers. None which have helped this far.
favorite_color= input(" what is your favorite color?")
I've tried multiple ways to solve this. i really need a walk through for the second part
1 Answer
Brandon White
Full Stack JavaScript Techdegree Graduate 35,771 PointsHi Miles,
I looked up the lesson/challenge you’re referring to, which is...
Use the favorite_color variable in your print function to output the following message to the screen :
The color [USER INPUTTED COLOR] is a great color!
I will respond with my favorite color when I run your script.
For instance, if I enter "purple" I want your code to print:
The color purple is a great color!
What you’ll want to do is print a formatted string. The string will be “The color _______ is a great color!” Only you’ll substitute the blank with the favorite_color variable as it will contain the user's input.
It’s important that you spell everything correctly, often times that’s the reason a student doesn’t pass the challenge. So don’t forget to include the exclamation mark at the end of your string.
Let me know if you still have issues completing the challenge.
Jason Anders
Treehouse Moderator 145,860 PointsJason Anders
Treehouse Moderator 145,860 PointsHi Miles Almas
You'll need to link to the question to which you are referring. The easiest way to do that is to click the Get Help button directly in the question.
Without the context of the question, it is impossible to help troubleshoot, as the code above in itself is correct, except for the extra space in the string at the beginning.
Please repost from the actual question you are stuck on.
Thanks :)