looping over a range

From: Jeanette C. <julien_at_mail.upb.de>
Date: Mon, 2 Aug 2021 13:51:10 +0200 (CEST)
Hey hey,
I'd love to loop a variable over a numerical range. the goal is to alternately 
process groups of measures on a track. I naively tried and failed with:
for beat in {1..100{ {
   g ($beat * 2);
   sel 2;
   if (($beat % 2) == 0) {
     ... # processing here
   } else {
     ... # Alternate processing here
   }
}

It failed, because the variable beat was set to 1:100. Short of putting in all 
the numbers I can't see how to achieve this goal. Any ideas, please?

Best wishes and TIA,

Jeanette

-- 
  * Website: http://juliencoder.de - for summer is a state of sound
  * Youtube: https://www.youtube.com/channel/UCMS4rfGrTwz8W7jhC1Jnv7g
  * Audiobombs: https://www.audiobombs.com/users/jeanette_c
  * GitHub: https://github.com/jeanette-c

We still move to a rhythm just like this
We still dream of sharing our first kiss <3
(Britney Spears)
Received on Mon Aug 02 2021 - 13:51:10 CEST

This archive was generated by hypermail 2.3.0 : Tue Aug 03 2021 - 01:34:23 CEST