xxxxxxxxxx
22
function setup() {
createCanvas(800, 1000);
}
function draw() {
background(255);
let colors =[color(0,0,255),color(255,0,0),color(0,200,0),]
noStroke();
translate(width / 2, 40);
for (let i = 0; i < 7; i++) {
push();
fill(colors[i%3]);
translate(0, i*i*20);
scale(5, 0.1 + i * 0.25);
rotate(PI / 4);
rect(0, 0, 100);
pop();
}
}