The missing card
Created on Dec. 22, 2018 by Julien Palard
Write a function named missing_card
that given a card game returns
the (single) missing card name.
The card game will be given as a single string of space-separated cards names.
A card is represented by its color and value, the color being in
{"S", "H", "D", "C"}
and the value being in {"2", "3", "4", "5", "6", "7",
"8", "9", "10", "J", "Q", "K", "A"}
, for a total of 52 possibilities.
You'll always be given 51 cards, and you have to return the missing one.
Example
1 2 3 4 5 6 7 8 |
|
should print CA
(beware, your function should return
, in my
example I used print
to print it).