Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW

comment on

( #3333=superdoc: print w/replies, xml ) Need Help??
What do you mean suit doesn't matter? In cribbage, you get 4 points if all 4 cards in your hand are the same suit. If you want to prove that no hand with a 5 isn't worth at least 2 points you HAVE to consider suits. You can easily use Re: Iterating over combinations to generate the hands. The hard part is the scoring.

On the other hand, it is a lot easier to prove that there is a hand of 5 cards containing at least 1 five that is a total of less than 2 points.

  • 4 cards (your hand) must not all be of the same suit
  • Must not contain any cards with a value of 10
  • Must not containing any combination (excluding the 5) whose sum is 10
  • Must not contain any 2, 3, or 4 of a kind
  • Must not have any sequence of greater than 2
I don't have an implementation yet, but it certainly does reduce the problem set.

Cheers - L~R

In reply to Re^5: Generating all 5-card hands by Limbic~Region
in thread Generating all 5-card hands by thor

Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":

  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.
  • Log In?

    What's my password?
    Create A New User
    and the web crawler heard nothing...

    How do I use this? | Other CB clients
    Other Users?
    Others lurking in the Monastery: (6)
    As of 2019-10-18 17:16 GMT
    Find Nodes?
      Voting Booth?