Skip to content

Problem Julian & Finn #6

@JulianEgbert

Description

@JulianEgbert

Maze

Problem

This is an interactive task where we simulated a Maze that is based on a grid. There are free tiles and walls (that occupy an entire tile). One is only given the status of the direct neighbors of the current tile that the user is on provided as 4 numbers (0 or 1) indicating wether the north, east, south and west tiles are either free or walls. Based on this the user should print a direction to go. When the exit is reached, the program will recieve the input "Exit" and should terminate.

Solution

With a recursive programm one can check all possible ways to go while remembering those fields that were already visited. This runs in linear time in regard to the number of fields of the maze.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions