This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import itertools | |
import random | |
els = range(10) # elements of the slot | |
wins_profile = dict() | |
wins_profile[0] = 65 | |
# wins_profile[10] = 15 # don't know any valid combo for this :-) | |
# wins_profile[20] = 10 # same here | |
wins_profile[50] = 5 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from scipy import stats | |
import pandas as pd | |
randgen = lambda n: [1 if i > .5 else 0 for i in stats.gamma.rvs(1, scale=0.7, size=n) > .5] | |
def truncate(l, n): | |
try: | |
ls = "".join(map(str, l)) | |
idx = ls.index("".join(map(str, [0] * n))) |
NewerOlder