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 trialMichael Ogobamidele
Courses Plus Student 1,514 PointsList I have tried this Question but it doesn't work
my_list=[ "1", "6", "4", "Apple", "Orange", "James" ] member=["We", "Gat"]
my_list=[
"1",
"6",
"4",
"Apple",
"Orange",
"James"
]
member=["We", "Gat"]
7 Answers
KRIS NIKOLAISEN
54,972 PointsWith what you have try:
my_list=[
1,
6,
4,
"Apple",
"Orange",
["We", "Gat"]
]
KRIS NIKOLAISEN
54,972 PointsSome things:
- numbers shouldn't be enclosed in quotes
- you only want two strings. you have added three
- the last list item in my_list should be another list
Nathan English
Front End Web Development Techdegree Student 10,817 PointsI believe its asking for a list inside a list like this.
my_list = ["mouse", [8, 4, 6], ['a']]
Michael Ogobamidele
Courses Plus Student 1,514 PointsIt doesn't work yet
Michael Ogobamidele
Courses Plus Student 1,514 PointsThis is the actual question: This challenge is just meant as a refresher. Create a single new list variable named my_list. Put 3 numbers and 2 strings into it in whatever order you want. For the last member, though, add another list with 2 items in it.
Michael Ogobamidele
Courses Plus Student 1,514 PointsThanks
Nathan English
Front End Web Development Techdegree Student 10,817 Pointsmy_list = [12,13,14,"apple","pear" [15,"orange"]]
This is the correct answer.