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 (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,271 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,271 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.