Question: rite a drawfunction to do the following.Create a grid of 6 rows and 10 columns (this makes a total of 60 squares in the grid).The

rite a "draw"function to do the following.Create a grid of 6 rows and 10 columns (this makes a total of 60 squares in the grid).The size of each square in the grid is 25x25 pixels.Each grid represents the amount of seconds on the clock (Hint: to get the seconds use the "second()"function).If the seconds have passed then the corresponding square is black and otherwise the square is white

let rows = 6;

let cols = 10;

let size = 25;

function setup() {

createCanvas(250, 200);

}

function draw() {

background(220);

let s = second();

}

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!