How can I make a temporary array and add items dynamically

I have a question about the temporary array in blueprint, as the image below.

I want to add items to a temporary array dynamically by ForLoop node, I use Make Array to make a array but I have nowhere to place that output variable I made, I know I can promote the array to variable but I don’t want to do so. How can I add items to a temporary array by ForLoop?

Thanks!
Ying

Are you sure the array needs to be temporary? The solution there would be to precreate an array and feed it to the Add node. If the problem is having it empty before starting this function, you can issue a Clear Array node before the forloop.

I don’t really like the ‘make array’ node as it’s more hardcoded than temp.

I would use a normal array for this situation.

When you later use “Remove Index” with value 0, it will also update the entire array (remove the row + resize the array).

I found that a function has a local variable but the event graph doesn’t. So I use a function instead. thank you all.