Small web app developed with Javascript that takes two hands of cards and evaluates which one wins using poker rules
Just open the file index.html in your prefered browser
Note: If you get any cross-domain error you might need to install a plugin on your browser to enable cross-origin resource sharing
Each hand consists in a set of five cards. One hand wins if its hand ranking is better. If two hands are ranked equally, then the hand with the highest value cards wins. If the two hands are both ranked equally and their highest cards are the same, then the second highests cards are compared, and so on. If they are still equal, it’s a tie.
- High Card: Highest value card. Order is 2, 3, 4, 5, 6, 7, 8, 9, Ten, Jack, Queen, King, Ace.
- One Pair: Two cards of the same value.
- Two Pairs: Two different pairs.
- Three of a Kind: Three cards of the same value.
- Straight: All cards are consecutive values.
- Flush: All cards of the same suit.
- Full House: Three of a kind and a pair.
- Four of a Kind: Four cards of the same value.
- Straight Flush: All cards are consecutive values of same suit.
- Royal Flush: Ten, Jack, Queen, King, Ace of same suit.