Python coin-toss
- by Andy
i am new to Python, and i can't wrap my head around this. I have following function defined:
def FlipCoins(num_flips):
heads_rounds_won = 0
for i in range(10000):
heads = 0
tails = 0
for j in range(num_flips):
dice = random.randint(0,1)
if dice==1: heads += 1
else: tails += 1
…