User Guide

730 Chapter 2: ActionScript Language Reference
set("name", "Jakob");
trace(name);
The following code loops three times and creates three new variables, called caption0, caption1,
and
caption2:
for (var i = 0; i<3; i++) {
set("caption"+i, "this is caption "+i);
}
trace(caption0);
trace(caption1);
trace(caption2);
See also
var, call()