Asked • 05/23/19

How to clone or copy a list?

What are the options to clone or copy a list in Python?While using `new_list = my_list`, any modifications to `new_list` changes `my_list` everytime.Why is this?

1 Expert Answer

By:

Matt S. answered • 05/24/19

Tutor
5.0 (65)

For Me, Data Science Is More Of An Art Than A Science

Still looking for help? Get the right answer, fast.

Ask a question for free

Get a free answer to a quick problem.
Most questions answered within 4 hours.

OR

Find an Online Tutor Now

Choose an expert and meet online. No packages or subscriptions, pay only for the time you need.