You have sets in Python 2.3x and 2.4x. I don't know if they can handle your amounts of data, but i guess so.