Revert "New version with VisitedLists instead of Sets - Slower though!!"

This reverts commit 1741c9b56ed3509e37f398cb93bb4cbb7fd9165f.
Reverted to better set implementation