Jump to content

Logic Question


ame1011
 Share

Recommended Posts

Hey there, I'm planning to build a texas hold'em program to calculate the % of making each type of hand both before the flop, and throughout the rest of the hand. My question is, what is the best way of going about this? I'm not looking for code, just discussion on how to best tackle this problem. Personally, the first thing that came to mind was to iterate through all possible combinations of cards being drawn and calculate %'s by adding the relative combinations. Although this is the most accurate way of doing this, there are

50*49*48*47*46 = 254251200
possible combinations for the remaining community cards. This would, of course, cause a huge slow down. The only other thing that comes to mind for me is to read my cards and visible community cards, and calculate the % to make each hand. IE: If I'm holding a Ace of Hearts and King of Hearts with no community cards showing, my % to make a royal flush with this hand is:
((50/3)*(49/2)*(48)) / (50*49*48*47*46) = .000077%
That seems like the way to go, anyone else have anything to add ? suggestions? comments? a mystery algorithm i dont know about?

Edited by ame1011
[font="Impact"] I always thought dogs laid eggs, and I learned something today. [/font]
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...