Python equivilent of pack()?

Skip Montanaro skip at
Tue Aug 24 20:43:55 CEST 1999

    Bit> My question is this: is there a functional equivilent to the Perl
    Bit> pack() and unpack() functions in Python? Or even better, is there
    Bit> an easier way to do what I want with Python? If not, how many
    Bit> people think this would be a useful addition to the Python standard
    Bit> library?


Check out the struct module docs at:

It'll most likely do just what you want.  It even calls its methods "pack"
and "unpack", so it should be fairly familiar to your Perl neurons...

Skip Montanaro |
skip at |
847-971-7098   | Python: Programming the way Guido indented...

More information about the Python-list mailing list