Added a helper to generate a random number

first time i've used coffeescript, hope it's ok!