Bugfixing - breaking while loop if starting point is on stacks top