xxxxxxxxxx
27
//skip 7th
let x;
let w;
function setup() {
createCanvas(400, 400);
w = width / 20;
}
function draw() {
background(250);
rect(140, 0, w, 400);
for (let i = 0; i < 20; i++) {
x = i * 20;
if (i !== 6) {
//skip 7th
if (mouseX > x && mouseX < x + w) {
fill("red");
} else {
fill(250);
}
rect(x, 0, w, 400);
}
}
}