Depth First Search

The simplest version of depth first search, how it gets stuck in loops and how to fix this using simple loop checking on the path.