Choo choo! In this multi-part coding challenge, I create a maze generator using a depth-first search algorithm with recursive backtracking. The idea is to walk through a grid of cells, removing walls as we go to build a maze. Code: thecodingtrain.com/challenges...
🕹️ p5.js Web Editor Sketch: editor.p5js.org/codingtrain/s...
Other Parts of this Challenge:
📺 Part 2: Visiting Neighboring Cells: • Coding Challenge #10.2...
📺 Part 3: Removing Walls: • Coding Challenge #10.3...
📺 Part 4: Backtracking: • Coding Challenge #10.4...
🎥 Previous video: • Coding Challenge #9: S...
🎥 Next video: • Coding Challenge 11: 3...
🎥 All videos: • Coding Challenges
References:
🌐 Maze Generation Algorithm: en.wikipedia.org/wiki/Maze_ge...
Videos:
🔴 Live Stream Archive: • Coding Train Live 35: ...
Related Coding Challenges:
🚂 #51 A* Pathfinding Algorithm: • A* Pathfinding Algorit...
🚂 #76 10Print: • Coding Challenge #76: ...
🚂 #171 Wave Function Collapse: • Coding Challenge 171: ...
Timestamps:
00:00 Introduction
01:15 What are we Building?
03:18 Create a Grid of Cells
08:10 Draw the 4 Walls Separately
11:03 The Anal Retentive Coder
12:30 Store the State of Walls for each Cell
15:07 Recap, See You in Part 2!
Editing by Mathieu Blanchette
Animations by Jason Heglund
Music from Epidemic Sound
🚂 Website: thecodingtrain.com/
👾 Share Your Creation! thecodingtrain.com/guides/pas...
🚩 Suggest Topics: github.com/CodingTrain/Sugges...
💡 GitHub: github.com/CodingTrain
💬 Discord: / discord
💖 Membership: ru-vid.comjoin
🛒 Store: standard.tv/codingtrain
🖋️ Twitter: / thecodingtrain
📸 Instagram: / the.coding.train
🎥 Coding Challenges: • Coding Challenges
🎥 Intro to Programming: • Start learning here!
🔗 p5.js: p5js.org
🔗 p5.js Web Editor: editor.p5js.org/
🔗 Processing: processing.org
📄 Code of Conduct: github.com/CodingTrain/Code-o...
This description was auto-generated. If you see a problem, please open an issue: github.com/CodingTrain/thecod...
#maze #recursion #backtracking #depthfirstsearch #p5js #javascript
1 июн 2024