Documentation ¶
Overview ¶
This module exports a Go port of CactusKev's poker Hand evaluator, source available here:
http://www.suffecool.net/poker/evaluator.html
Also, it integrates paul senzee's perfect hash variant to get a 2.7x speedup:
http://www.paulsenzee.com/2006/06/some-perfect-hash.html
*
- Created with IntelliJ IDEA.
- User: hcombs
- Date: 8/3/13
- Time: 10:40 AM
- To change this template use File | Settings | File Templates.
Index ¶
Constants ¶
View Source
const CARDS_IN_DECK = 52
View Source
const CARDS_IN_HAND = 5
View Source
const CARD_MASK = 0xFF
View Source
const NUM_HAND_TYPES = 10
View Source
const RANK_MASK = 0x0F00
View Source
const SUIT_MASK = 0xF000
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Deck ¶
type Deck [CARDS_IN_DECK]Card
type Hand ¶
type Hand [CARDS_IN_HAND]Card
type HandRank ¶
type HandRank uint8
func HandRankFromScore ¶
return the corresponding HandRank for a given value
Click to show internal directories.
Click to hide internal directories.