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!
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
Copy a list with slices
I am doing the quiz for slices and there is this question where they ask how to copy a list with slices.
they want you to copy a_list = [1, 2, 3]
I know how to make a copy, for instance:
a_list = [1, 2, 3] my_list = a_list[:]
which copies the entire a_list. But I don't know what to type in to get it right.
Steven Parker228,105 Points
The blank in the question only represents the slice syntax. It might be confusing because the copy being made won't be saved anywhere (there's no assignment being made).
So just answer with the characters you would add to the list to make a copy.