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
Смотрите видео Random Walker in p5.js (Coding Challenge 52) онлайн без регистрации, длительностью часов минут секунд в хорошем качестве. Это видео добавил пользователь The Coding Train 27 Январь 2017, не забудьте поделиться им ссылкой с друзьями и знакомыми, на нашем сайте его посмотрели 131,761 раз и оно понравилось 2.4 тысяч людям.