Skip to content

Instantly share code, notes, and snippets.

@emre
Created June 4, 2014 20:23
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save emre/4c1fc6e38107dad1d1d0 to your computer and use it in GitHub Desktop.
Save emre/4c1fc6e38107dad1d1d0 to your computer and use it in GitHub Desktop.
rng
import random
sides = ["head", "tail"]
results = {
"head": 0,
"tail": 0,
}
for i in xrange(1, 1001):
side = random.choice(sides)
results[side] += 1
print results
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment