Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?

Re^2: calculating cribbage points

by thor (Priest)
on Mar 31, 2006 at 15:07 UTC ( #540486=note: print w/replies, xml ) Need Help??

in reply to Re: calculating cribbage points
in thread calculating cribbage points

The thing about scoring mutiples (pairs, 3-of-a-kind, 4-of-a-kind) in cribbage is that it all just breaks down to scoring pairs. 3-of-a-kind is worth 6 points because there are 3-choose-2 pairs (which is 3) in a 3-of-a-kind. Each pair being worth 2 points yields 6 points total. So, using similar techniques as stated already in this thread, one can generate the set of all pairs and if the two elements in the pair are the same, increment the count of pairs.


The only easy day was yesterday

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://540486]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others musing on the Monastery: (5)
As of 2020-06-05 03:49 GMT
Find Nodes?
    Voting Booth?
    Do you really want to know if there is extraterrestrial life?

    Results (35 votes). Check out past polls.