Skip to content

kodykodec/NDTysonCoinFlipSimulation

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 

Repository files navigation

NDTysonCoinFlipSimulation

https://www.youtube.com/watch?v=uTChrirK-hw at time 5:55 in video

This is a small program to simulate a thought experiment presented by Neil Degrasse Tyson. N number of participants are to flip a coin, if a person gets tails they exit the game, if a person gets heads they stay alive and flip again. This is repeated until there's one person left standing.

*Some limitations - In the experiment it is assumed that the N number of particpants flip a coin simultaneously. In the code I wrote this isn't the case. N participants are created and then iterated through one by one for a coin flip and then results are logged after each round.

I don't have the knowledge on multi-threading or other know how to simulate multiple instances flipping the coin.

Open to suggestions