Challenge:
In the last stage of a two players Texas hold 'em, given a two-card hand and five cards on table, determine your probability to win versus an opponent by the standard ranking of poker hands.
Input:
Seven cards (sdtin or arguments). The first two cards are your hand while the last five are on the table. Each card will be a two letter string of the form RS where R is rank and S is suit. The ranks range from 2-9, T for ten, and J, Q, K, and A for Jack, Queen, King, and Ace respectively. The suits are H, D, C, S for Hearts, Diamonds, Clubs, and Spades respectively.
Output:
The probability to win (stdout or return): from '0.00' to '1.00'.
Input to Output Examples:
AH 7C KH QH JH TH 6C -> 1.00
Explanation: You have a royal flush, 100% winning chances.
9H 7C KH QH JH TH 6C -> 0.96
Explanation: You have a straight flush, your opponent can only win with an AH, 95.6% winning chances.
Rules and Clarifications:
- There are 52 different cards. You can refer to Texas hold 'em to get the idea.
- Your opponent has 2 unknown cards (out of 45 left). That's 990 possibilities with equal probability.
- You are free to decide if Ties count or don't count in the calculation of the probability.
- As this is code golf, the shortest answer wins.