Jesus Cea <jcea <at> jcea.es> writes: > > Mike Coleman wrote: > > I guess if ints are 12 bytes (per Beazley's book, but not sure if that > > still holds), then that would correspond to a 1GB reduction. > > Python 2.6.1 (r261:67515, Dec 11 2008, 20:28:07) > [GCC 4.2.3] on sunos5 > Type "help", "copyright", "credits" or "license" for more information. > >>> import sys > >>> sys.getsizeof(0) > 12
On a 32-bit system, sure, but given Mike creates a 45 GB dict, he has a 64-bit system, where ints are 24 bytes: >>> sys.getsizeof(0) 24 >>> sys.getsizeof(100000) 24 cheers Antoine. _______________________________________________ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com