Random doubles inadvertently rounded to zero

Due to operator precedence, random doubles are being cast to int before multiplication. As values returned by Math.random are on the interval [0, 1], the values returned will always be 0 under an integer cast.