'FreeMarker: How to create a list of variable based on an given number
I would like to create a list of variable with specific naming, number of variables being dynamic
Input: NumberOfItems Output: <#assign Item0 =""> <#assign Item1 =""> .... <#assign ItemNumberOfItem ="">
How can I proceed, knowing that I can't use [nbr] in the name of the variable if I proceed through <#list 1..NumberOfItems as nbr>
Thanks!
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
