Added a long (time) to accelerate the random() speed