fixed bugs in sets.py