Class: AcpcPokerTypes::PileOfCards

Inherits:
Array
  • Object
show all
Defined in:
lib/acpc_poker_types/pile_of_cards.rb

Direct Known Subclasses

Hand

Instance Method Summary collapse

Instance Method Details

#to_poker_hand_strengthInteger

Returns The strength of the strongest poker hand that can be made from this pile of cards.

Returns:

  • (Integer)

    The strength of the strongest poker hand that can be made from this pile of cards.



7
8
9
# File 'lib/acpc_poker_types/pile_of_cards.rb', line 7

def to_poker_hand_strength
  HandEvaluator.rank_hand map { |card| card.to_i }
end