I don't see a function to return quick trick count in the evaluate namespace. Does something exist which I can use?
If not available, I can just fallback to the following code:
qtl = [(2,'AK'),(1.5,'AQ'),(1,'A'),(1,'KQ'),(0.5,'K')] # list of (quick tricks card combos, combo value)
qtls = sorted(qtl,reverse=True) # sort by quick trick value (most to least) to avoid ambiguity
def SuitToQT(suit):
# assumes suits are sorted by HCP value (most to least) (AKQJT...)
for qt in qtls:
if suit.startswith(qt[1]):
return qt[0]
return 0
I don't see a function to return quick trick count in the evaluate namespace. Does something exist which I can use?
If not available, I can just fallback to the following code: