Recognizing strings as instance names

I have something like this as a part of my code




var gen:particle;
var a:int = 0;
var b:int = 1;

for (var i:int=0; i<100; i++)
{
    gen = new particle();
    addChild(gen);
    gen.x = a;
    a = a+20;
    gen.name = ("n" + i);
}

addEventListener(Event.ENTER_FRAME, loop2);

function loop2(e:Event)
{
    for(var i:int=0; i<100; i++)
         {
     
         }
    
}



As you can see i am creating instances of *particle *and adding them stage and then giving them instance names.

Now in the empty event handler function I want to access these instances of particle I created by their instance names and change their rotationX values.

The question is how do I call these instance names in the for loop in the second function. I can generate the string pretty easily, but how do I get flash to recognize these strings as instance names?