Path: csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!gegeweb.org!de-l.enfer-du-nord.net!feeder2.enfer-du-nord.net!feeds.phibee-telecom.net!newsfeed.xs4all.nl!newsfeed5.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.043 X-Spam-Evidence: '*H*': 0.92; '*S*': 0.01; 'int': 0.05; 'function,': 0.07; 'sizeof': 0.09; '>>>': 0.12; 'message- id:@glegroupsg2000goo.googlegroups.com': 0.16; 'reply- to:addr:comp.lang.python': 0.16; 'to:addr:comp.lang.python': 0.16; 'float': 0.16; 'cc:addr:python-list': 0.17; 'bytes': 0.19; 'header :In-Reply-To:1': 0.21; 'cc:no real name:2**0': 0.23; 'subject:?': 0.29; 'received:209.85.160': 0.29; 'cc:addr:python.org': 0.30; 'cc:addr:gmail.com': 0.30; 'header:User-Agent:1': 0.35; 'cc:2**1': 0.35; 'received:google.com': 0.37; 'received:209.85': 0.37; 'subject:: ': 0.38; 'received:209': 0.39; 'to:addr:googlegroups.com': 0.63; 'header:Reply-To:1': 0.72; 'reply-to:no real name:2**0': 0.72; 'reply- to:addr:googlegroups.com': 0.73; 'subject:this': 0.76; 'subject:there': 0.91; 'subject:better': 0.93 Newsgroups: comp.lang.python Date: Mon, 23 May 2011 11:55:08 -0700 (PDT) In-Reply-To: Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=115.242.185.214; posting-account=OXUUTgoAAAC6LctOTfOqWD3ky9QBr6MJ User-Agent: G2/1.0 X-Google-Web-Client: true MIME-Version: 1.0 Subject: Re: Is there a better way to solve this? From: kracekumar ramaraju To: comp.lang.python@googlegroups.com Content-Type: text/plain; charset=ISO-8859-1 Cc: python-list@python.org, Ganapathy Subramanium X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.12 Precedence: list Reply-To: comp.lang.python@googlegroups.com List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Message-ID: Lines: 8 NNTP-Posting-Host: 82.94.164.166 X-Trace: 1306176916 news.xs4all.nl 49042 [::ffff:82.94.164.166]:48794 X-Complaints-To: abuse@xs4all.nl Xref: x330-a1.tempe.blueboxinc.net comp.lang.python:6087 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