Playing with Random
Playing with Random
Today, we'll specifically look at the Random function.
Completed
Basics of HTML & CSS
Block-based Programming
Code Comments
Basics of Animation
Today
More P5.js
Making Chaos with Random
Upcoming
More P5.js
More JavaScript
Part 0: Overview of the Function
Our focus today is on the Random Function.
This function allows us to generate pseudo-random numbers.
I say pseudo because true random is actually really hard to do.
This is more than close enough for us though.
First, let's learn a bit about it.
Most of today's content comes from NYU Professor, Dan Shiffman.
Part 1: Using Random in Code
Next, Prof. Shiffman will show us how we can implement the random function in a simple program that draws a square.
Part 1b: Detour
Before we go on... this gave me a few ideas based on what else we've been doing recently.
Let's try a bit of randomness with loops.
Part 2: What Else?
Let's finish up today with Prof. Shiffman.
He'll briefly discuss a few other ideas on how we could play with the random function.
Add videos of your experimentation to today's slide.