Follow procedure half the time? in Developer Help
for(var/n in 1 to 10)
if(!(n % 2))
world << n
Check the DM Reference entry for the % operator. It simply gives the remainder of A divided by B.
In the example I provided, it checks if A%B is 0, which is the case in even numbers divided by 2.
Name a single even number that, divided by 2, leaves a remainder that is not 0.