added statistics and random name picking logic