how to do every "x" amount of objects

so right now i want to put every like 10 or so objects into an array but leave the rest out. can anybody point me in the right direction? heres what i have so far i need something for the if satement.

var instantiateObject : Transform;

var gridX = 10;
var gridY = 10;


function Start () {
tileArrayY = new ArrayList();
tileArrayX = new ArrayList();

	for ( var x = 0; x < gridX; x++){
		
		for (var y = 0; y < gridY; y++){
		
			var myName = Instantiate(instantiateObject, Vector3(x *.5,0,y * .5), Quaternion.identity);
			myName.name = "x: " + x + "y: " + y;
			
			if(){
			tileArrayX.Add(myName.gameObject);
			}
			
			else{
			
			tileArrayY.Add(myName.gameObject);
				
			}	
		}
		
 	} 
print("This is your YArray: " + tileArrayY[0]);
print("This is your XArray: " + tileArrayX[0]);
print("This is your YArray: " + tileArrayY[1]);
print("This is your XArray: " + tileArrayX[1]);
}

if( (x+y) % someNumber == 0 )
tileArrayX.Add(…)

% means modulo, which is basically what is left over if you remove the right hand value as often from the left hand value as possible. So two examples:

7 % 3 == 1 //because 7-3-3 = 1 and you can't remove the 3 any more often then that
9 % 6 == 3

So by checking if modulo someNumber == 0 you pick every someNumber.