creating a nested loop

geotrupede's icon

I am trying to get a nested loop with metro, count and uzi.
But I am finding it difficult.

In tcsh this could be:
foreach (1 2 3)
foreach (1 2 3 4)
...
end
end

In matlab it would be
for i = 1:3
for j = 1:4
...
end
end

Max Patch
Copy patch and select New From Clipboard in Max.

but in Max?
See enclosed map, which does not work.

please help.
G

Wetterberg's icon
Max Patch
Copy patch and select New From Clipboard in Max.

You didn't really say what you wanted your patch to *do*, but if I'm correct in assuming you want it to draw vertical bars of random length, then the fix is in the message ordering - hope this helps:

(ninja-edit that also fixes another bug in the design) (and even more compact)

geotrupede's icon

Fantastic!!!!
thank you.
G