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

My 1st task is showing correct result, but when i work on my next 2nd tasks it shows that my 1st task is wrong,pls help

My 1st task is showing correct result, but when i work on my next 2nd tasks it shows that my 1st task is wrong, again working on my 1st task with same output it shows correct. please help

strings.py
subject = "Treehouse loves{}"
print(subject.format('Ashish'))

2 Answers

My 1st task is showing correct result, but when i work on my next 2nd tasks it shows that my 1st task is wrong,pls help

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

you don't need to print anything here. you just need to basically combine your first line with the second half of your print line, so you would have subject = ... like you have, then after the treehouse loves string, that's where you call the format method, and the argument to the format method is the name variable from task 1. also don't delete what you did on task 1.

Thanks, ill try!

Hey can you answer both the Tasks, so that I can check them