Skip to main content

constants/
lib.rs

1/// The number of players in the game.
2pub const PLAYER_COUNT: usize = 2;
3
4/// The number of cards dealt to each player's hand at the start of a round.
5pub const CARDS_DEALT_PER_HAND: usize = 6;
6
7/// The number of cards each player keeps in their hand after discarding.
8pub const CARDS_KEPT_PER_HAND: usize = 4;
9
10/// The number of cards each player discards to the crib.
11pub const CARDS_DISCARDED_TO_CRIB: usize = CARDS_DEALT_PER_HAND - CARDS_KEPT_PER_HAND;
12
13/// The target score for the play phase, where players lay down cards.
14pub const PLAY_TARGET: usize = 31;
15
16/// The score required to win the game.
17pub const WINNING_SCORE: usize = 121;