Skip to content

Instantly share code, notes, and snippets.

@IndhumathyChelliah
Created August 30, 2021 22:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save IndhumathyChelliah/bf88c75da8e955ee3516da9b0cdee6c3 to your computer and use it in GitHub Desktop.
Save IndhumathyChelliah/bf88c75da8e955ee3516da9b0cdee6c3 to your computer and use it in GitHub Desktop.
#modifying original_list
original_list.append(99)
#Output:[1, 2, 3,99]
print(copied_list)
#Output:[1, 2, 3,99]
print(id(original_list))
#Output:26751688
print(id(copied_list))
#Output:26751688
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment