Created
September 24, 2022 11:01
-
-
Save petrosDemetrakopoulos/8040b5aab076cafe05b1d8e098214eb7 to your computer and use it in GitHub Desktop.
Texas Holdem Monte Carlo
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
def monte_carlo(hand, table, players=2, samples=10000): | |
dist = [0,0,0] | |
for i in range(samples): | |
outcome = simulate(hand, table, players) | |
dist[outcome] += 1 | |
return list(map(lambda x: x/samples, dist)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment