This is about scoring poker hands in general, and just lowest score wins. leaving out the logic for scoring pair or higher hands, sorting the hand in ascending order, and then appending all missing card (units 1-13) in ascending order, lets you use A. (anagram) to score the hand.
A. 9 10 11 12 13 1 2 3 4 5 6 7 8 4183603200 A. 8 10 11 12 13 1 2 3 4 5 6 7 9 3704601600 above compares king high straight to an 8 replacement for the 9. Lowest anagram wins. A. 0 1 2 3 4 5 6 7 8 9 10 11 12 13 0 A. 0 1 2 3 4 6 5 7 8 9 10 11 12 13 40320 A. 0 1 2 3 4 7 6 5 8 9 10 11 12 13 85680 On Sunday, May 9, 2021, 03:43:32 p.m. EDT, Devon McCormick <[email protected]> wrote: I'm working on some code to work with low poker hands (as in a game like Omaha or lowball). Since not everyone is familiar with this domain, I've put together a wiki page outlining what this means and the code I have so far: https://code.jsoftware.com/wiki/User:Devon_McCormick/Poker/Lowball . This may be part of the NYCJUG meeting ( https://www.meetup.com/J-Dynamic-Functional-Programming/) in a few days, so any suggestions are welcome. Thanks! -- Devon McCormick, CFA Quantitative Consultant ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm
