Created
June 13, 2018 05:54
-
-
Save niinpatel/4cb1f7caf6f2e3f766e0d55b46e603b5 to your computer and use it in GitHub Desktop.
This file contains 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
function simulateGame(num, toSwitch) { | |
let gamesWon = 0; | |
for(let i = 0; i < num; i++){ | |
gamesWon += playMontyHall(toSwitch) | |
} | |
return gamesWon | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment