# Just a little problem here...with arrays

**URL:** <https://forum.kirupa.com/t/just-a-little-problem-here-with-arrays/153712>\
**Category:** flash\
**Created:** [July 4, 2005, 3:36am UTC](https://forum.kirupa.com/t/just-a-little-problem-here-with-arrays/153712 "2005-07-04T03:36:52Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![hweiee](https://avatars.discourse-cdn.com/v4/letter/h/4bbf92/32.png) [@hweiee](https://forum.kirupa.com/u/hweiee)\
**Post date:** [July 4, 2005, 3:36am UTC](https://forum.kirupa.com/t/just-a-little-problem-here-with-arrays/153712/1 "2005-07-04T03:36:52Z")

</div>

Hi, how can i create a 2D array that has “emptyslot” initially stored in every of its slot. My code is:

grid = new Array();  
for (j=1;j\<=10;j++){  
for (i=1;i\<=6;i++){  
grid\*[j] = “emptyslot”;  
}  
}

Then i did the trace on a blank movieclip:

onClipEvent (enterFrame){  
trace(grid);  
}

It returned:

Undefined  
Undefined  
Undefined  
Undefined  
Undefined  
Undefined  
Undefined  
Undefined  
Undefined

etc etc…
