[Tutor] struct question

W W srilyk at gmail.com
Tue Feb 3 19:29:27 CET 2009


On Tue, Feb 3, 2009 at 6:25 PM, bob gailer <bgailer at gmail.com> wrote:

> >>> struct.calcsize('s')
> 1
> >>> struct.calcsize('d')
> 8
> >>> struct.calcsize('sd')
> 16
>
> Why? Should not that be 9?
>

>>> struct.calcsize('ds')
9

at least on the current box I'm running. It also gave me this:

>>> struct.calcsize('sd')
12

so I must confess suspicion...

HTH though,
Wayne
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/tutor/attachments/20090203/266db7d7/attachment.htm>


More information about the Tutor mailing list