This script is called the Monte Carlo Method. It was created by Stanislaw Ulam. It sets two random variables, var1 and var2, but only outputs var1. Var1 is more likely to be 10 then 1 because the while loop keeps repeating setting var1 and var2 to random numbers from 1 through 10 until var1 is greater than or equal to var2. Because of that, 10 has a 1 out of 90 percent chance of being picked for each repeat, while 1 has a 1 out of 100 percent chance of being picked for each repeat.