Re: 7 Card Hand Evaluators
Follow up. Trying to figure out how u map from table 5 to 6, or table 6 to a final hand value without large memory requirements. There about 2.5 Million combinations 5 cards, thust your table would seem to require 2.5 million combinations, yielding a table 6 that is lil over 100 MB.
The one way i thought around this is that your tables may already be condensed using equivalence classes, so the numbers could be smaller. That is, maybe if I wrote the big tables, and backwards eliminated duplicates, it would condense.
Did you do something like that, or totally different?
P.s. your tables lookups for c1 through c3 would probably be a pretty small part of your table(s).
Why not just write them as an array (52,52,52) and put duplicate values in the array to that (1,2,3) = (3,2,1). Looking up a single value from a multi dimensional array is usually much faster than looking up values from 3 different arrays, and performing addition between each lookup.
|