# Efficiently creating/populating a 20x20 cell matrix

**URL:** <https://forum.kirupa.com/t/efficiently-creating-populating-a-20x20-cell-matrix/301472>\
**Category:** Uncategorized\
**Created:** [December 9, 2009, 7:03pm UTC](https://forum.kirupa.com/t/efficiently-creating-populating-a-20x20-cell-matrix/301472 "2009-12-09T19:03:54Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![jdulberg](https://avatars.discourse-cdn.com/v4/letter/j/71e660/32.png) [@jdulberg](https://forum.kirupa.com/u/jdulberg)\
**Post date:** [December 9, 2009, 7:03pm UTC](https://forum.kirupa.com/t/efficiently-creating-populating-a-20x20-cell-matrix/301472/1 "2009-12-09T19:03:54Z")

</div>

Hello,

I have a 20x20 matrix set up in Excel that I’d like to recreate in Flash. Essentially the values are either 0 or a calculated formula of -Fo or 1+2(Fo).

My question is with a matrix of this size, is there an efficient way to create and populate it besides hard coding the address for each data cell? Can I make this using a loop?

I’ve attached a snippet of what the Excel sheet looks like. Notice the data trend.

Any suggestions would be really helpful! Thanks.  
Jason
