N-nested For loops, with N variable - Best way to implement?

*To*: mathgroup at smc.vnet.net*Subject*: [mg60743] N-nested For loops, with N variable - Best way to implement?*From*: lost.and.lonely.physicist at gmail.com*Date*: Tue, 27 Sep 2005 03:45:15 -0400 (EDT)*Sender*: owner-wri-mathgroup at wolfram.com

Hello everyone I'd like to seek some advice regarding how to best implement N nested For loops such that (1) N is a variable - i.e. I tell Mathematica what N is and it does the For loop N times. (2) For each loop I want to do something like For[a_k=1,a_k<=A,a++, ...], k = 1,...,N and I want to use the all the running values {a_1,...,a_N} to do stuff within the innermost loop. Maybe there's even a way to do this w/o using For loops? Table maybe? Thanks for the advice.

**Follow-Ups**:**Re: N-nested For loops, with N variable - Best way to implement?***From:*Sseziwa Mukasa <mukasa@jeol.com>