Skip to content

A Recursive VS Iterative Dynamic Backtracking Maze Generator with C++

Notifications You must be signed in to change notification settings

jbarciv/Backtracking-Maze-Generator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 

Repository files navigation

Recursive VS Iterative Dynamic Backtracking Maze Generator with C++

Description

The next respository has two C++ programs. Both implement a Dynamic Maze Generator with a ramdomized version of the depth-first search algorithm (for more information read this). One program uses a recursive method and the other an iterative method.

Installation

$ git clone https://github.com/jbarciv/Recursividad-PS/

Change your directory to the one where you have clone the repository. Choose between the Iterative or Recursive program and move to this folder and type:

$ make

you will be using the Makefile for compiling and linking all the .cpp files.

Usage

The program asks you the dimensions for the maze:

For running the program you have some options (we'll be using as an example the recursive program). Just type this:

$ ./Maze_Recursive

You pass the dimesions directly to the maze:

$ ./Maze_Recursive 30 45

The firts number is the vertical size (number of rows) and the second one is the horizontal size. 30 and 45 are just examples, try to play whit differents dimesions. I recommend you using a number of columns larger than the number of rows, it will be more square.

Testing mode:

$ ./Maze_Recursive 30 45 1

With a third parameter you can activate the testing mode. You won't see the maze, just the results of time and iterations.

Acknowledgments

I would like to thank to Celia Ramos and Gonzalo Quirós for all his help during the completion of this work.

About

A Recursive VS Iterative Dynamic Backtracking Maze Generator with C++

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published