Two plus Two Poker hand evaluator: how do cards compare to integers?

In an attempt to build the fastest carlo texas handheld magnetic analyzer with C ++, I am currently researching the topic of hand scoring.

As many of you may know, there are quite a few open source manual evaluators out there. After a little thought, I settled on the "Evaluation with two plus points" (so I called it, since it was first presented at two plus two forums).

It is one of the fastest estimators known and uses an array lookup to quickly find the value of a hand.

Now for the function you need to pass an array with the maps you are interested in. Example:

int Cards[] = { 3, 5, 10, 17, 23, 24, 32 };
int hv = HandValue(Cards);

      

With values ​​from 1 to 52. Now, my question is: Which cards do these integers correspond to? Is 3 aces of spades? Three hearts? I went through google, two + two forums, various pages that show hand evaluators, source file to grow array. All in vain. So I hope someone here can point me in the right direction where I can find this information, or pass it on to me directly.

The source the evaluators come from is a great article: http://www.codingthewheel.com/archives/poker-hand-evaluator-roundup#cactus_kev This explains all the evaluators individually.

+3


source to share


1 answer


I have not confirmed this, but it looks like this:

"2c": 1,
"2d": 2,
"2h": 3,
"2s": 4,
"3c": 5,
"3d": 6,
...
"kh": 47,
"ks": 48,
"ac": 49,
"ad": 50,
"ah": 51,
"as": 52

      



ref: https://github.com/chenosaurus/poker-evaluator/blob/master/lib/PokerEvaluator.js

+4


source







All Articles