In this coding challenge, I simulate a "random walk" with the p5.js library. This video is part of the course Nature of Code at ITP, Tisch, NYU. Code: https://thecodingtrain.com/challenges...
🕹️ p5.js Web Editor Sketch: https://editor.p5js.org/codingtrain/s...
🎥 Previous video: • A* Pathfinding Algorithm (Coding Chal...
🎥 Next video: • Coding Challenge #53: Random Walker w...
🎥 All videos: • Coding Challenges
References:
🚶🏽♀️ Random walk Wikipedia article: https://en.wikipedia.org/wiki/Random_...
5️⃣ random Function Reference Page: https://p5js.org/reference/#/p5/random
5️⃣ floor Function Reference Page: https://p5js.org/reference/#/p5/floor
📕 The Nature of Code GitHub (Spring 2017): https://github.com/nature-of-code/NOC...
Live Stream Archive:
🔴 Live Stream #73: • Live Stream #73: Random Walk
Related Coding Challenges:
🚂 #53 Random Walker with Vectors and Lévy Flight: • Coding Challenge #53: Random Walker w...
🚂 #162 Self Avoiding Walk: • Coding Challenge 162: Self-Avoiding Walk
Timestamps:
0:00 Introduction to the Random Walker Coding Challenge
1:56 Whiteboard explanation of a random walk
6:48 Into the code...drawing a point!
7:30 Picking a random number between 0 and 4 using p5.js's 'random' and 'floor' functions
9:58 Setting up the code to use the random number
12:26 First run! The point...it wibbles...it wobbles
12:48 Stop clearing the background every frame so that we can see the point's path
13:10 Discussion of the possibilities of the random walker
Editing by Mathieu Blanchette
Animations by Jason Heglund
Music from Epidemic Sound
🚂 Website: http://thecodingtrain.com/
👾 Share Your Creation! https://thecodingtrain.com/guides/pas...
🚩 Suggest Topics: https://github.com/CodingTrain/Sugges...
💡 GitHub: https://github.com/CodingTrain
💬 Discord: / discord
💖 Membership: http://youtube.com/thecodingtrain/join
🛒 Store: https://standard.tv/codingtrain
🖋️ Twitter: / thecodingtrain
📸 Instagram: / the.coding.train
🎥 Coding Challenges: • Coding Challenges
🎥 Intro to Programming: • Start learning here!
🔗 p5.js: https://p5js.org
🔗 p5.js Web Editor: https://editor.p5js.org/
🔗 Processing: https://processing.org
📄 Code of Conduct: https://github.com/CodingTrain/Code-o...
This description was auto-generated. If you see a problem, please open an issue: https://github.com/CodingTrain/thecod...
#random #floor #randomwalker #p5js #javascript #processing #java
Watch video Random Walker in p5.js (Coding Challenge 52) online without registration, duration hours minute second in high quality. This video was added by user The Coding Train 27 January 2017, don't forget to share it with your friends and acquaintances, it has been viewed on our site 131,761 once and liked it 2.4 thousand people.