Sha256: 3a9c66e6c72f82c93bae95fae392eff310cda629095b7544f756f95a3f092c7d

Contents?: true

Size: 594 Bytes

Versions: 1

Compression:

Stored size: 594 Bytes

Contents

module CardsLib
  module Standard
    module Rankers
      class BlackjackRanker < CardsLib::Ranker
        def initialize(card)
          super(
            card,
            {
              "2" => 2,
              "3" => 3,
              "4" => 4,
              "5" => 5,
              "6" => 6,
              "7" => 7,
              "8" => 8,
              "9" => 9,
              "T" => 10,
              "J" => 10,
              "Q" => 10,
              "K" => 10,
              "A" => 11
            },
            ->rank{@ranks[rank]}
          )
        end
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
cards_lib-0.2.5 lib/cards_lib/standard/rankers/blackjack_ranker.rb