Pulsating rectangle inside a grid, location changing?

Hi all! I am fairly new to OF and I am trying to the following as an exercise:

I want to create a grid of squares (one square = function) with for loop (done). I would like the squares pulsate one by one, starting in the upper left corner and then passing the pulsation to the second square on the right (or below of the first one). I know how to make the whole grid pulsate with sin, mapping and rectangle size. In order to pass the pulsating effect to only square at time, I wonder if I should use a vector? I am not experienced with vectors yet so any examples etc. are welcome. Many thanks!