Bitsets in Python
Matt
matt_crypto at yahoo.co.uk
Thu Feb 5 08:50:57 EST 2004
More information about the Python-list mailing list
Thu Feb 5 08:50:57 EST 2004
- Previous message (by thread): Bitsets in Python
- Next message (by thread): Bitsets in Python
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Josiah Carlson <jcarlson at nospam.uci.edu> wrote: > > does Python have any native support for bitsets? I dont seem to see > > anything in the standard library? > > What do you mean 'bitsets'? Give a list of functionality of your > 'bitsets', and it will be easy for us to tell you whether Python > includes it. BitSets crop up in (at least) C++ and Java. They allow you operate on a sequence of bits using a friendlier interface than hacking about with ^,|,& et al on integers. The Java BitSet interface: http://java.sun.com/j2se/1.4.1/docs/api/java/util/BitSet.html I can't find anything like it in the standard library (If I've overlooked it, I'd be chuffed to find out I'm wrong!). The OP might find the following Cookbook recipe useful, though: http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/219300 (At least I think so, I can't access the site at the moment...) Matt
- Previous message (by thread): Bitsets in Python
- Next message (by thread): Bitsets in Python
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Python-list mailing list