On Monday, September 28, 2015 at 11:24:40 AM UTC-4, Giuseppe Ragusa wrote: > > I am having problems (serious problems!) to deal with algorithms that boil > down do nested for loops but whose number of loops is not known at compile > time. As an example consider this: >
In this sort of algorithm, I usually employ recursion (on the dimension being looped over), where the base case is 1 or 2 nested loops (big enough to amortize the recursion overhead).