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.

Ira Salem
10,331 PointsWhat am I doing wrong?
Can anybody tell me what's wrong with this code?
full_name = "Ira Salem"
name_list = list(full_name)
2 Answers
William Li
Courses Plus Student 26,867 PointsHi, Ira, you need to use the split method to solve this problem
name_list = full_name.split(" ")
The when you call the list on a string, in your case, list(full_name)
, it'll return a list by split the string character by character ['I', 'r', 'a', ' ', 'S', 'a', 'l', 'e', 'm']
. That's not quite what the question is asking for.

Ira Salem
10,331 PointsIt's crazy but I don't recall him ever showing that we could even use the .split method that way. Either that or I'm not taking very good notes. Thanks anyway. I'll give it a try soon as I get home.

Kenneth Love
Treehouse Guest TeacherHey Ira Salem. It's a couple of videos back but we definitely used .split()
on a string.

Ira Salem
10,331 PointsPerhaps I should utilize the transcript portion more. I'll definitely go back and look.
Ira Salem
10,331 PointsIra Salem
10,331 PointsCreate a variable named full_name that holds your full name. Make another variable named name_list that holds your full name as a list, split on the spaces. Don't create name_list manually!