Template:For loop/doc

This template implements a for loop or a foreach loop.

This template calls a user-specified template (the "called template") multiple times: once for each value in either 1) an iterated sequence or 2) an explicit list. Each value in the sequence or list is passed to the same specified parameter of the called template (the "variable parameter"). Optionally, pre- and postfixes can be attached to the passed values.

In addition to the specified variable parameter, other parameters of the called template ("static parameters") can be given a value which is the same in each iteration.