Hacker News new | ask | show | jobs
by pmarreck 340 days ago
TIL about Lehmer codes... and "poker encoding" ;)

(I just prefer poker to solitaire...)

Someone else mentioned that the orientation of the cards (up or down) and possibly even the front-back facingness of the card (facing up, facing down) would add another 2 possible bits to the available encoding space. (Of course, at that point you'd have to also encode which side of the whole deck is the "top"...)

My own thought was to add par2 to make it robust against small errors... at the cost of some transmission space!

3 comments

> Of course, at that point you'd have to also encode which side of the whole deck is the "top"...)

An asymmetrical joker could indicate which short edge is "right way up", while also indicating which card is the first or last of the deck.

> "...which side of the whole deck is the 'top'..."

A dark line drawn across the top of the deck would be enough. Though it would ruin the stealth factor of the cards.

Also, the pattern on the back of some playing decks isn't symmetrical, so that could be used as well.

Decode it both ways and see which isn't gibberish.
Use a casino decommissioned deck. They typically have either a hole punched in them, or a corner cut off. Either way it won't be symmetric, but still perfectly plausible as a cheap deck of cards.
Yeah that would make an interesting addition. I was thinking about error correction so if you swapped two cards it would be okay but was struggling with how it would work, but I think it would be quite fun to add :)