Need elegant way to cast four bytes into a long

Skip Montanaro skip at pobox.com
Fri Aug 8 12:15:53 EDT 2003


    >> You can use struct.unpack as well, though I'd be hard-pressed to get
    >> the details correct.  You'd be better off with "pydoc struct".

    gustavo> Kinda like this?

    ...

Yeah.  Since I don't really use the struct module, I was a bit wary of
getting the details wrong in an example without a little trial-and-error and
reading-of-documentation.

Skip





More information about the Python-list mailing list