Shallow Copy and Deep Copy in Python 3

preview_player
Показать описание
The copying process occurs recursively in a deep copy. A new collection is first created, then it gets recursively populated with copies of child objects found in the original.

Shallow copying is not recursive unlike deep copy, a new collection object is constructed and it's populated with references to the child objects found in the original, however, these are only references, not the actual copies itself.
Рекомендации по теме
Комментарии
Автор

Good tutorial, but holy fuck please treat your keys with some love. Even through the microphone I could hear the key smash.

silverchain
Автор

please, if you don't know or not clear, then dont try to explain. True; u need to get video hits, but not at the cost of misleading people. What you explain is half stuff. From your explanation shallow copy and list assignment are same.

grenjith
welcome to shbcf.ru