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 (Retired) Shopping List Lists and Strings

greeting_list challenge - stuck on Task 4

Here's my code...

full_name = "Alec Burmeister"
name_list = full_name.split()
greeting_list = "Hi, I'm Treehouse".split()

greeting_list[2] = name_list[0]

greeting = greeting_list.join()

I could swear this is what I'm being asked to do, and I don't know what could be the issue. If you could lighten the path on my mistake, I would really appreciate it!

greeting = greeting_list.join() is the error. the error is: It looks like Task 1 is no longer passing... or something. I understand what it's saying and all I just don't know why it's not passing when I do what i'm being asked to do.

[edit formatting -cf]

1 Answer

Chris Freeman
MOD
Chris Freeman
Treehouse Moderator 68,423 Points

Yes, the join() statement is the issue. Try:

greeting = ' '.join(greeting_list)

This says, "Use the string ' ' (a single space) to join the elements of the list greeting_list