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 trialCheri Watts
658 PointsOoops! Task 1 no longer passing!
full_name="Cheri Watts" name_list=full_name.split() greeting_list=("Hi", "I'm", "Treehouse").split()
full_name="Cheri Watts"
name_list=full_name.split()
greeting_list=("Hi", "I'm", "Treehouse").split()
3 Answers
Andreas cormack
Python Web Development Techdegree Graduate 33,011 PointsHi Cheri
The second part of the challenger asks you to create a list from the string "Hi, I'm Treehouse". You create a list from a string by calling the split method on the string which normally splits the string on spaces or on any other delimiter you specify. The error in your code is your adding parentheses around the string.
list = "firstname lastname".split() # this is how you create a list from a string.
Cheri Watts
658 PointsThank you for your assistance, Andreas. I believe I tried what you suggested and the Ooops! Task 1 no longer passing re-occurred. I don't want to feel this frustrated so this is probably not the option for me to learn Python. I will need Treehouse to exit the beta testing stage if they are in beta testing. I hate to think that they released this program from beta testing without repairing this bug...
:(
Andreas cormack
Python Web Development Techdegree Graduate 33,011 PointsHi Cheri
There is nothing wrong with the challenge at all. The above code was an example to show you how the split method works. This is what the code should look like to pass the first two stages of the challenge.
full_name="Cheri Watts"
name_list=full_name.split()
greeting_list= "Hi, I'm Treehouse".split()
let me know if you need anymore assistance.
Brian Gillespie
725 PointsBrian Gillespie
725 PointsEDIT: Treehouse showed a link to the original task after my first comment. So here's what you should be doing for the final part of the task:
You could also use -1 in place of the 2 for the index into greeting_list. -1 would mean the last item, -2 would mean the second-to-last item, and so on.