Batch declaration and access to variables via identifiers specified by text - var_by_txt()
You can create a large number of variables with names that are formed as text strings.
For example, in a loop, create variables from "var_1_1_1" to "var_100_100_100".
Convenient for forming n-dimensional arrays, etc.
You can then access variables directly:
s = var_67_45_34;
Or assign
var_34_23_23 = "value for 34_23_23";
And you can also assign values to a variable whose name is formed on the fly in the line:
for (i = 1; i <= 100; i++)
{
for (j = 1; j <= 100; j++)
{
for (k = 1; k <= 100; k++)
{
var_by_txt("set", "var_"+itoa(i)+"_"+itoa(j)+"_"+ itoa(k),
"value for variable " + itoa(i) + "_" + itoa(j) + "_" + itoa(k));
}
}
}