Skip to content

Instantly share code, notes, and snippets.

@ksc91u
Created November 18, 2020 13:39
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 ksc91u/809f76f01652be015527e6a276d67c4f to your computer and use it in GitHub Desktop.
Save ksc91u/809f76f01652be015527e6a276d67c4f to your computer and use it in GitHub Desktop.
python const integer 0-255
#!/usr/bin/env python3
a=5
print(hex(id(a)))
b=2+3
print(hex(id(b)))
c=300
print(hex(id(c)))
c+=1
print(hex(id(c))) #new instance of c created
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment