Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Oh, you're so random

Oh, you're so random

Randomness and pink ponies in Codemotion Rome 2012

Vicent Martí

March 25, 2012

Transcript

77 slides
  1. how to FIX: 1. Random is hard 2. Run away

    Math.random() // between 0.0 and 1.0 Javascript
  2. how to FIX: 1. Random is hard 2. Run away

    prng.rand(5..9) #=> one of [5, 6, 7, 8, 9] prng.rand(5...9) #=> one of [5, 6, 7, 8] Ruby
  3. this is bad and you should feel bad! MANY fixes

    (but only one is right) 1. Limiting request size

More Decks by Vicent Martí

Other Decks in Programming