# Maze Navigation



## Maximilianjava (6. Jun 2022)

Implement Ariadne's thread by conducting a depth-first search


Create a class EscapeRoute, which implements the search for the exit.
EscapeRoute needs to implement the following constructor and methods:






public EscapeRoute()
public int getPathLength()
public void search(Cell startingCell)



The search method starts at a given cell and proceeds as follows:


Explore the maze in the direction of the upper cell
Explore the maze in the direction of the right cell
Explore the maze in the direction of the down cell
Explore the maze in the direction of the left cell
I.e. we are proceeding clockwise. Your search ends, when you found the exit. I.e. the cell with its _id_ set to −1−1. Use recursion to implement your depth-first-search.

Do not forget to mark cells as visited while exploring the maze. Store the number of visited cells along your path. The method getPathLength() should return this value.

In which order are your cells visited?


Hier komme ich nicht mehr weiter hat jemand eventuelle Lösungensansätze ?


----------



## httpdigest (6. Jun 2022)

Maximilianjava hat gesagt.:


> hat jemand eventuelle Lösungensansätze ?


Ja. Hast du denn keine? Und warum nicht? Wo hakt es denn genau?


----------



## Maximilianjava (6. Jun 2022)

Er findet es irgendwie nicht


----------



## httpdigest (6. Jun 2022)

"Er" "findet" "es" nicht? Was meinst du mit "er", was mit "findet", und was mit "es"? 
Es heißt vermutlich nicht "visisted", sondern "visited".


----------

