Implemented valid set finder