Questions tagged [card-games]
For challenges which involve card games. This includes playing the game, implementing the game, as well as challenges concerned with individual mechanics and analysis of the game (for instance, computing probabilities of certain events).
86
questions
3
votes
1
answer
125
views
Detect revokes in Jass
Jass is a trick-taking game for four players and the national card game of Switzerland. It is played with a 36-card deck, four suits each with ranks 6, 7, 8, 9, 10, J, Q, K, A. We will be using French ...
2
votes
1
answer
178
views
Determine the optimal blackjack move
After the success of my baccarat challenge, I figured we should try a similar challenge for another casino game, blackjack.
Blackjack is a game played with two to eight decks of cards shuffled ...
11
votes
8
answers
3k
views
Should the banker hit?
Baccarat is a casino game where gamblers bet on whether one of two hands, the player or the banker, will have a sum closer to 9 (mod 10) or whether they will tie. It is played with four to eight ...
-10
votes
1
answer
406
views
Bingo Cards PDF
Write code to generate a PDF file containing 6 bingo cards. Winner is the one that uses the shortest code and needs no actions except for installing a library and running the code. (No Save As PDF). ...
6
votes
1
answer
242
views
Determine if a Spider Solitaire game is stale
Let's introduce a simplified variant of the well known Spider Solitaire.
From Wikipedia:
The main purpose of the game is to remove all cards from the table, assembling them in the tableau before ...
14
votes
13
answers
3k
views
Play a game of memory
Playing the game of memory against a machine is highly unfair, because they play almost as good as small children. So let's make the machine play alone, but in a fair way:
Input: 1...26 pairs of ...
2
votes
1
answer
394
views
King of the Cards
King of the Cards
Code available here!
In this King of the Hill challenge, you must write a bot that can play Crazy Eights. This is a card game often played by children, in which the objective is to ...
13
votes
9
answers
2k
views
Magic: the Gathering - Colour Sorting
Related: Deck Names Friends or Foes Paying for Spells
The Magic: the Gathering card game has five colours of magical mana: white (W), blue (U), black (B), red (R), and green (G). Cards can be any of ...
3
votes
0
answers
191
views
Calculate the probability of getting this hand in n tries [closed]
Imagine there is a card game where the primary objective of the game is to get 4 of one card in your hand.
Game mechanics
Each player starts of with 10 cards in their hand. The remaining 32 cards (...
7
votes
1
answer
326
views
Heart Point Generator
It's mentioned last time that, in Hearts,
Each round every player gets a non-negative amount of points. The sum of the points is 26, and at least one player gets 13 or more points.
Actually, it's ...
10
votes
4
answers
293
views
Is it a possible Hearts result?
Hearts is a 4-player game that uses the following scoring rules:
Everyone starts with score 0.
Each round every player gets a non-negative amount of points. The sum of the points is 26, and at least ...
14
votes
3
answers
763
views
Snap (card game)
When I was a child I used to play a variation of Snap to stake soccer trading cards.
"Game" is an overstatement because the only role of the players is to secretly prepare their starting ...
1
vote
0
answers
306
views
FreeCell stack moving
This question is about moving stacks around in the card game FreeCell, but here it will be presented more abstractly.
Given three integers \$0\le n,m<10000,0<k<10000\$.
There are \$m+2\$ ...
9
votes
3
answers
517
views
Turn-based RPS Poker
This is a two-player card game which resembles a vastly simplified game of Texas Hold'em,
combined with RPS (rock-paper-scissors) and the most basic mechanic of commercial turn-based card games.
The ...
6
votes
6
answers
924
views
Let's play Judgement!
In this king-of-the-hill challenge, you will be making a python 3 bot to play the card game judgement!
Sandbox
Rules
Judgement is a hand based game similar to games like rummy. In each round,
7 cards ...