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
26 changes: 13 additions & 13 deletions Specification.md
Original file line number Diff line number Diff line change
@@ -1,31 +1,31 @@
#The Specification
####Having a specification means we have something to test, to narrow the scope let's keep the problem small so we can make easy, incremental progress.
# The Specification
#### Having a specification means we have something to test, to narrow the scope let's keep the problem small so we can make easy, incremental progress.


##*1 Terminology*
## *1 Terminology*

####The common terms we will use are listed here:
#### The common terms we will use are listed here:

####`Suit` - which include:-
#### `Suit` - which include:-

Clubs, Diamonds, Hearts and Spades

####`Rank` - A rank is the value of the card:-
#### `Rank` - A rank is the value of the card:-

Ace, Two, Three, Four,
Five, Six, Seven, Eight,
Nine, Ten, Jan, Queen, King

####`Card` - Combination of `Suit` and `Rank`
####`Deck` - A collection of `Card`s (`unshuffled` more detail below)
####`Deal` - The `Deal` is a *action* that operates on the `Deck` and takes the first `Card` within the `Deck`. The remaining `Deck` should have 1 fewer `Card` in it.
#### `Card` - Combination of `Suit` and `Rank`
#### `Deck` - A collection of `Card`s (`unshuffled` more detail below)
#### `Deal` - The `Deal` is a *action* that operates on the `Deck` and takes the first `Card` within the `Deck`. The remaining `Deck` should have 1 fewer `Card` in it.

####`Shuffle` - The `Shuffle` is an action that operates on the `Deck` and randomly shuffles the `Card`s within the `Deck`
#### `Shuffle` - The `Shuffle` is an action that operates on the `Deck` and randomly shuffles the `Card`s within the `Deck`

##*2 The unshuffled deck*
## *2 The unshuffled deck*
####An unshuffled deck will be in alphabetical suit order then for each suit in rank order ascending and starting from the Two to Ace, like so:-

**`Clubs = ♣, Diamonds = ♦, Hearts = ♥, Spades = ♠`**
** `Clubs = ♣, Diamonds = ♦, Hearts = ♥, Spades = ♠`**

Deck consists of
♣ with Ranks in order [2, 3, 4, 5, 6, 7, 8, 9, 10, J, Q, K, A]
Expand All @@ -35,5 +35,5 @@

This means that the first `Card` from an `Unshuffled Deck` is an `Two` of `Clubs` and the last `Card` is a `Ace` of `Spades`.

##*3 Other cards*
## *3 Other cards*
A `Deck` will not contain any `Joker`s