I wrote a Javascript function and a loop whose role is to call my function, each time with a different parameter. My idea was that the iterator will help me use a different variable each time but obviously this doesn't work. I figured out that my problem is that when the loop calls the function, the parameter is a string rather than an object name. Any way to save that or the idea was flawed from the beginning?
var a0 = [1,2,3];
var a1 = [4,5,6];
var a2 = [7,8,9];
function myFunction (parameter) {instructions;}
for (i=0; i<3; i++)
myFunction("a"+i);