Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BasicCardStrengthDeterminer ¶
Determines the card strength based on the order of the given card, AKQJT98765432.
func SortRanksByStrength ¶
This function defines how to sort a list of ranks by its strength
func WildcardCardStrengthDeterminer ¶
Determines the strength of the card exactly like in BasicCardStrengthDeterminer but moving 'J' to the bottom
Types ¶
type Card ¶
type Card struct {
// contains filtered or unexported fields
}
Type representing a Card in the Camel Cards game the valid values are: A, K, Q, J, T, 9, 8, 7, 6, 5, 4, 3, or 2
type Hand ¶
type Hand struct { HandType HandType // contains filtered or unexported fields }
Represents a hand in the Camel Cards game
type HandType ¶
type HandType int
Represents the Hand type, based on the given cards
Ordered from less to more value
func BasicHandDeterminer ¶
Calculates which HandType should be used of a given set of cards. It does not return any error, as it does not check that the cards are valid.
func WildcardHandDeterminer ¶
The function takes into account that 'J' are comodin cards, and therefore, can count towards other types