Skip to content

Instantly share code, notes, and snippets.

@AABoyles
Created December 29, 2015 16:37
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 AABoyles/f90d43b093be7472901f to your computer and use it in GitHub Desktop.
Save AABoyles/f90d43b093be7472901f to your computer and use it in GitHub Desktop.
import random
exclusive = 0
def bad(thing_name, chance):
x = random.random()
if x < chance:
print (thing_name)
if thing_name in ("The person is in prison", "The person is on probation", "The person is in a nursing home", "The person is unemployed"):
exclusive = 1
bad("The person is in prison", 0.01)
bad("The person experienced domestic abuse this year", 0.01)
bad("The person was sexually abused as a child", 0.1)
bad("The person was physically abused as a child", 0.2)
bad("The person has been raped", 0.09)
bad("The person has chronic pain", 0.2)
bad("The person is clinically depressed", 0.07)
bad("The person is cognitively disabled", 0.02)
bad("The person has schizophrenia", 0.01)
bad("The person has dementia", 0.02)
bad("The person is wheelchair-bound", 0.01)
bad("The person is an alcoholic", 0.07)
bad("The person is a heroin addict", 0.005)
if exclusive == 0:
bad("The person is on food stamps", 0.20)
if exclusive == 0:
bad("The person is unemployed", 0.05)
if exclusive == 0:
bad("The person is on disability", 0.03)
if exclusive == 0:
bad("The person is on probation", 0.02)
if exclusive == 0:
bad("The person is in a nursing home", 0.01)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment