static void testAll()
        {
            (int, int)mazeDimenations = (Console.WindowWidth - 8, Console.WindowHeight - 5);

            Console.ForegroundColor = ConsoleColor.Green;
            Console.Write("generating maze...");

            var mazes = new HashSet <HashSet <Point> >();

            var thread = new Thread(
                () =>
            {
                mazes.Add(BoruvkasAlgorithm.generateMaze(mazeDimenations.Item1, mazeDimenations.Item2));
            });
            var thread2 = new Thread(
                () =>
            {
                mazes.Add(PrimsAlgorithm.generateMaze(mazeDimenations.Item1, mazeDimenations.Item2));
            });
            var thread3 = new Thread(
                () =>
            {
                mazes.Add(KruskalsAlgorithm.generateMaze(mazeDimenations.Item1, mazeDimenations.Item2));
            });
            var thread4 = new Thread(
                () =>
            {
                mazes.Add(RecursiveBacktrackerAlgorithm.generateMaze(mazeDimenations.Item1, mazeDimenations.Item2));
            });
            var thread5 = new Thread(
                () =>
            {
                mazes.Add(HuntandKill.generateMaze(mazeDimenations.Item1, mazeDimenations.Item2));
            });

            var threadList = new List <Thread>
            {
                thread,
                thread2,
                thread3,
                thread4,
                thread5
            };

            foreach (var t in threadList)
            {
                t.Start();
            }
            ;


            Console.Clear();

            if (thread.IsAlive | thread2.IsAlive | thread3.IsAlive | thread4.IsAlive)
            {
                Console.ForegroundColor = ConsoleColor.Red;
                Console.Write("generating mazes...");
            }

            while (thread.IsAlive | thread2.IsAlive | thread3.IsAlive | thread4.IsAlive)
            {
                //if a maze is still being generated then don't go onto the code below
            }

            Console.SetCursorPosition(0, 0);
            Console.ForegroundColor = ConsoleColor.Red;
            Console.Write("finished generating mazes");

            foreach (HashSet <Point> maze in mazes)
            {
                setBothColours(ConsoleColor.White);
                printMaze(maze);
                Depth_first_Search.solveMaze(maze);
                Thread.Sleep(800);

                resetWindow();
            }
        }
        public static HashSet <Point> generateMaze(int width, int height)
        {
            var availableVertices = RecursiveBacktrackerAlgorithm.ReturnDict(width, height).Keys.ToList();

            var maze = new HashSet <Point>();

            var usedVertices = new HashSet <Point>();

            var weights = BoruvkasAlgorithm.returnEdgeWeights(width, height, availableVertices);
            var V       = BoruvkasAlgorithm.assignInitialSetNumbers(availableVertices);

            var mazeEntry = new Point(5, 2);

            maze.Add(mazeEntry);

            //pick random edge/lowest weight edge
            //combine set of connected trees IF NOT IN THE SAME SET
            //remove edge
            //repeat

            while (!BoruvkasAlgorithm.singleSet(V))
            {
                foreach (Point v in availableVertices)
                {
                    var lowestWeightEdge = BoruvkasAlgorithm.returnLowestWeightEdge(weights);

                    if (lowestWeightEdge.IsEmpty)
                    {
                        continue;
                    }

                    var connectedVertices = BoruvkasAlgorithm.returnNodes(availableVertices, lowestWeightEdge);

                    var setNumber1 = V[connectedVertices.First()];
                    var setNumber2 = V[connectedVertices.Last()];


                    if (setNumber1 != setNumber2)
                    {
                        V = BoruvkasAlgorithm.assignSetNumber(V, setNumber1, setNumber2);

                        weights.Remove(lowestWeightEdge);

                        if (!maze.Contains(connectedVertices.First()))
                        {
                            maze.Add(connectedVertices.First());
                        }
                        if (!maze.Contains(connectedVertices.Last()))
                        {
                            maze.Add(connectedVertices.Last());
                        }
                        maze.Add(lowestWeightEdge);
                    }
                    weights.Remove(lowestWeightEdge);
                }
            }

            var mazeExit = RecursiveBacktrackerAlgorithm.returnExit(width, height);

            maze.Add(mazeExit);

            return(maze);
        }