You can use sizeof function, >>> a=12234 >>> b=23456.8 >>> a.__sizeof__() 12 >>> b.__sizeof__() 16 So sizeof int is 12 bytes and float is 16 bytes -- http://mail.python.org/mailman/listinfo/python-list
- Is there a better way to solve this? Ganapathy Subramanium
- Re: Is there a better way to solve this? Chris Rebert
- Re: Is there a better way to solve this? kracekumar ramaraju
- Re: Is there a better way to solve this? David Robinow
- Re: Is there a better way to solve this? Terry Reedy
- Re: Is there a better way to solve this? Steven D'Aprano