amir650 / MyCardGame

6 stars 3 forks source link

Error #1

Open trenkvaz opened 5 years ago

trenkvaz commented 5 years ago

Hello !

Why is it an error ?

Exception in thread "main" java.lang.RuntimeException: should not reach here in 5 card poker : FULL_HOUSE : hole cards [KING of CLUBS, ACE of SPADES] : community cards [QUEEN of SPADES, KING of HEARTS, KING of SPADES, ACE of DIAMONDS, ACE of CLUBS] vs FULL_HOUSE : hole cards [FIVE of CLUBS, ACE of HEARTS] : community cards [QUEEN of SPADES, KING of HEARTS, KING of SPADES, ACE of DIAMONDS, ACE of CLUBS] at com.cardgames.poker.shared.PokerHandComparator.compareFullHouseHands(PokerHandComparator.java:129) at com.cardgames.poker.shared.PokerHandComparator.compare(PokerHandComparator.java:38)

That is legal holdem combination

Regards, Alexey

amir650 commented 5 years ago

Hi Alexey,

Did you write a new test case or is that an existing one? I'd like to try and reproduce it myself before I draw any conclusions.

best regards, Amir

On Sun, Aug 11, 2019 at 3:17 AM trenkvaz notifications@github.com wrote:

Hello !

Why is it an error ?

Exception in thread "main" java.lang.RuntimeException: should not reach here in 5 card poker : FULL_HOUSE : hole cards [KING of CLUBS, ACE of SPADES] : community cards [QUEEN of SPADES, KING of HEARTS, KING of SPADES, ACE of DIAMONDS, ACE of CLUBS] vs FULL_HOUSE : hole cards [FIVE of CLUBS, ACE of HEARTS] : community cards [QUEEN of SPADES, KING of HEARTS, KING of SPADES, ACE of DIAMONDS, ACE of CLUBS] at com.cardgames.poker.shared.PokerHandComparator.compareFullHouseHands(PokerHandComparator.java:129) at com.cardgames.poker.shared.PokerHandComparator.compare(PokerHandComparator.java:38)

That is legal holdem combination

Regards, Alexey

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/amir650/MyCardGame/issues/1?email_source=notifications&email_token=AARB4OW35LV5EKJL3PHEHP3QD7RLZA5CNFSM4IK3O6QKYY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4HESL3IQ, or mute the thread https://github.com/notifications/unsubscribe-auth/AARB4OX7NPCBRXW7ZTNF4G3QD7RLZANCNFSM4IK3O6QA .