Welcome to the Treehouse Community

The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.

Python Python Basics (2015) Python Data Types String Formatting

Paul Landrum
Paul Landrum
508 Points

Answer to question worked in the python workspace, but wasn't correct on the quiz.

name = "Paul Landrum" subject = "Treehouse loves {}" print(subject.format(name))

This was correct in the workspace, but didn't get the answer right on the quiz, thus I can't move forward. Please help.

In the future, when I don't get an answer right but I want to move on, do I have to always ask a question?

strings.py
name = "Paul Landrum"
subject = "Treehouse loves {}"
print(subject.format(name))

2 Answers

james south
seal-mask
.a{fill-rule:evenodd;}techdegree seal-36
james south
Front End Web Development Techdegree Graduate 33,258 Points

the challenge does not ask you to print anything. you basically just need to combine your last two statements. subject = .....the string they want.....then call format on that like you are in your print statement.

james south
seal-mask
.a{fill-rule:evenodd;}techdegree seal-36
james south
Front End Web Development Techdegree Graduate 33,258 Points

challenge survival guide: do only and exactly what the challenge asks, nothing more, nothing less. don't have any typos, missing punctuation, syntax errors, missing brackets, etc. don't erase or modify your code from previous tasks unless explicitly requested to. if it says a previous task is no longer passing, you have probably introduced an error in the current task. finally, especially when you are just starting out, search the forum to see if other people have asked your question before.