regenerating random variables on each iteration slows it down