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

can't find the solution

i'am trying and trying with this task but i never get it right.

6 Answers

Ken Alger
STAFF
Ken Alger
Treehouse Teacher

Mladen;

The code challenge checker can be rather picky. You should be fine without concatenating the place holder with the string. I believe the challenge instructions show it as Treehouse loves {} without breaking it apart.

Post back if you are still stuck.

Happy coding,
Ken

Hello Ken,

name = "Mladen"
subject = "Treehouse loves " + "{}".format(name)

I'm using same code on Python anywhere and it works. can't understand why it dosent accept my answer at treehouse /Mladen

[MOD: added ```python markdown formatting]

Chris Freeman
Chris Freeman
Treehouse Moderator 67,989 Points

This solution should have been accepted. Tagging Kenneth Love to review grader restrictions.

Thank you Andreas! Keep up the good work with Python.

Ken Alger
STAFF
Ken Alger
Treehouse Teacher

Mladen;

Can you post the code you have been trying?

Thanks,
Ken

Thank you, it work's! /Mladen

I actually found the code is this thread to be more helpful:

https://teamtreehouse.com/community/works-in-console-but-doesnt-pass-the-challenge