Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ When you finish talk with another pair and walk through your answers.

## Part 2: Calculating a Score

You will write a method called: `blackjack_score` which take an array of card values and returns the blackjack score. The card values can be any of the following, number values 1-9, "King", "Queen", "Jack". If the array contains an invalid card value or the total exceeds 21, raise an `ArgumentError`. For example `blackjack_score([1, 5, 3])` will return 19. You should also raise an error if the hand contains more than 5 cards.
You will write a method called: `blackjack_score` which take an array of card values and returns the blackjack score. The card values can be any of the following, number values 2-9, "King", "Queen", "Jack", "Ace". If the array contains an invalid card value or the total exceeds 21, raise an `ArgumentError`. For example `blackjack_score(["Ace", 5, 3])` will return 19. You should also raise an error if the hand contains more than 5 cards.

In this exercise you will complete the given tests in `test/blackjack_score_test.rb` and updating the `blackjack_score` method in `lib/blackjack_score.rb` to make it pass.

Expand Down