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 Collections (2016, retired 2019) Lists Combining Lists

George Lugo
George Lugo
Python Web Development Techdegree Student 922 Points

what is wrong with my code

best = ["chicken", "johnson", "able"] best.extend(["yams","corn"]) best.insert(["start"],[0])

best = ["chicken", "johnson", "able"]

1 Answer

Hi George,

You're pretty close,

You have the arguments to insert() in the wrong order. It should be the index first, and then the value you want to insert.

Also, the index is a simple integer and should not have brackets around it.

And you want to insert the string "start", not the list ["start"]. So the brackets have to be removed there as well.

Let me know if you're still stuck.