Примерно так, наверное:
def info(o:object):
print([o.__class__, str(o.__sizeof__()) + ' bytes', o.__hash__()])
s = 'Hello world'
info(s)
Copyright © 2024 SCHOLAR.TIPS - All rights reserved.
Answers & Comments
Примерно так, наверное:
def info(o:object):
print([o.__class__, str(o.__sizeof__()) + ' bytes', o.__hash__()])
s = 'Hello world'
info(s)