update random number