Cycle-Break Algorithm