# For each

**URL:** <https://forum.kirupa.com/t/for-each/272920>\
**Category:** Uncategorized\
**Created:** [October 9, 2008, 12:17pm UTC](https://forum.kirupa.com/t/for-each/272920 "2008-10-09T12:17:11Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![brndn](https://avatars.discourse-cdn.com/v4/letter/b/dec6dc/32.png) [@brndn](https://forum.kirupa.com/u/brndn)\
**Post date:** [October 9, 2008, 12:17pm UTC](https://forum.kirupa.com/t/for-each/272920/1 "2008-10-09T12:17:11Z")

</div>

for each(var b:MovieClip in SYM)  
{  
for each(var c:MovieClip in SYM\_MAIN)  
{  
if(b.hitTestObject©) trace("\*\*\*\*in winner")  
}  
}

could anyone help me with this. I have these loops but they dont do exactly what I am wanting.

i want the items in the arrays to match up.  
this way they all trace.

if you cast your eye at these two arrays you should get my probelm

var SYM:Array = [cartouche.symbol1, cartouche.symbol2, cartouche.symbol3, cartouche.symbol4];

var SYM\_MAIN:Array = [emblem.symbol1, emblem.symbol2, emblem.symbol3, emblem.symbol4];

cheers if anyone can help out.

brndn
