Article View: rec.games.programmer
Article #870Re: Cribbage Algorithm Wanted
From: Dr. Cat
Date: Wed, 26 Aug 1992 08:15
Date: Wed, 26 Aug 1992 08:15
8 lines
909 bytes
909 bytes
Well, since you're dealt only 6 cards, there are only 30 possible four card hands you can be left with after choosing two to discard. If you write a scoring algorithm (which you'll need for the game anyway), it wouldn't be hard to simply scan all the possible alternatives and select the highest scoring one. You might want to put some weighting factors in for cards that are more likely to gain value when the top card of the deck is combined with them - jacks and 2 card sequences are good, and 5s aren't bad either.
Technical Details
Message-ID:
<1992Aug26.081558.9483@wixer.cactus.org>Path:
arc1-ca.pugleaf.net!sparky!uunet!cs.utexas.edu!milano!cactus.org!wixer!catReferences:
<BtKF09.JE1@news.cso.uiuc.edu>Show Full Headers
Complete Article Headers
Newsgroups: rec.games.programmer Path: arc1-ca.pugleaf.net!sparky!uunet!cs.utexas.edu!milano!cactus.org!wixer!cat From: cat@wixer.cactus.org (Dr. Cat) Subject: Re: Cribbage Algorithm Wanted Message-ID: <1992Aug26.081558.9483@wixer.cactus.org> Keywords: cribbage Organization: Real/Time Communications References: <BtKF09.JE1@news.cso.uiuc.edu> Date: Wed, 26 Aug 92 08:15:58 GMT Lines: 8