first passing tests of weightedrandom
random working