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 trialSandraLee Rowe
3,637 PointsI've tried all the possible solutions that came to mind, but I'm still unsure where I might be making a mistake.
favorite_color=input ('purple')
purple=input ('The color purple is a great color!')
2 Answers
Travis Alstrand
Data Analysis Techdegree Graduate 49,443 PointsHey SandraLee Rowe !
So for the first part of the challenge it's asking us to prompt the user "What is your favorite color? " and save their response to a favorite_color
variable.
favorite_color = input("What is your favorite color? ")
For the second part of the challenge, it needs to be dynamic so that no matter what color the user inputs, it will be added into the string. It also mentions we need to print
the message so we don't need another variable here. We'll need to close the strings and use commas to separate the values like in the previous videos.
print("The color ", favorite_color, "is a great color!")
I hope this makes sense!
SandraLee Rowe
3,637 PointsAwesome thank you for helping me.
Travis Alstrand
Data Analysis Techdegree Graduate 49,443 PointsYou're very welcome!