Skip to content

Instantly share code, notes, and snippets.

View tanweer-mahdi's full-sized avatar
🧩
~ i know the pieces fit ~

Shah Mahdi Hasan tanweer-mahdi

🧩
~ i know the pieces fit ~
View GitHub Profile
@JackMcKew
JackMcKew / shallow-vs-deep-copy.py
Last active August 17, 2020 00:05
Shallow vs Deep Copy in Python
import copy
A = [1,2,[3,4],5]
print("A contents: ",A)
# OUTPUT: A contents: [1, 2, [3, 4], 5]
B = A
print(f"A's object id is {id(A)}")