Defining a matrix with size determined at runtime

Hello people!

I need to define a matrix with a size that is determined at runtime. I remember seeing it somewhere but I can't remember where or how to do it. The folloowing doesn't work anyway:

string $faces[] = ls pSphereShape1.f[ * ];
matrix $facesPos[size($faces)][3];

Btw... does anyone have any tips on how to get the position of a face without having to loop through all verts of a face?

Thanks a million!