Speed-up Statist.getRandomIndex()

Signed-off-by: SharplEr <sharplermc@gmail.com>