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 trialJothum Chitewe
7,833 Pointsstring formatting
use. format () on the string "treehouse loves {}" to put your name into the placeholder. assign this to the variable subject( so start with subject=). no need to print anything.
subject="Treehouse loves {}"
print(subject.format("treehouse loves"))
1 Answer
Henrik Christensen
Python Web Development Techdegree Student 38,322 PointsVery close, but all you have to do is add .format() to the subject variable - like this:
subject = "Treehouse loves {}".format(name)