submission by jtoy
function setup(){
  var myCanvas = createCanvas(windowWidth,windowHeight); //you must keep this line   
    rows = width/20
    cx = width / 2
    cy = height / 2
    noStroke()
  }

  function draw() {
    background(0,3)

    for (i = 0; i < rows; i++) {
      fill(i*253%255,i*45%255,i*1.3%255)
      m = (i%2 == 0) ? 50 :  -50
      rect(cx +m, i * 50, sin(millis()/(1000*i))*m, cos(millis()/(1000*i))*m)
      rect(i * 50,cy +m,  cos(millis()/(1000*i))*m, sin(millis()/(1000*i))*m)
    }
  }