Re: Самое быстрое определение покерной комбинации — Часть 2 ID:25245 ответ на 25243 |
Пт, 26 октября 2007 00:33 [#] |
|
|
Комбинации:
<div style="margin:20px; margin-top:5px">
<div class="smallfont" style="margin-bottom:2px">Код:</div>
<pre class="alt2" dir="ltr" style="
margin: 0px;
padding: 4px;
border: 1px inset;
width: 640px;
height: 242px;
text-align: left;
overflow: auto">const
COMBINATION_BLANK = 00;
COMBINATION_ACE_KING = 01;
COMBINATION_ONE_PAIR = 02;
COMBINATION_TWO_PAIRS = 03;
COMBINATION_THREE_KIND = 04;
COMBINATION_SKIP_STRAIGHT = 05;
COMBINATION_WRAP_STRAIGHT = 06;
COMBINATION_STRAIGHT = 07;
COMBINATION_FLUSH = 08;
COMBINATION_FULL_HOUSE = 09;
COMBINATION_FOUR_KIND = 10;
COMBINATION_STRAIGHT_FLUSH = 11;
COMBINATION_ROYAL_FLUSH = 12;</pre>
</div>Структура карты:
<div style="margin:20px; margin-top:5px">
<div class="smallfont" style="margin-bottom:2px">Код:</div>
<pre class="alt2" dir="ltr" style="
margin: 0px;
padding: 4px;
border: 1px inset;
width: 640px;
height: 114px;
text-align: left;
overflow: auto">type
PCard = ^TCard;
TCard = packed record
Kind, Suit, Mask, XorMask: Word;
SuitIndex, ID, R1, R2: Word;
end;</pre>
</div>
|
|
|