1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
/*
DDS, a bridge double dummy solver.
Copyright (C) 2006-2014 by Bo Haglund /
2014-2018 by Bo Haglund & Soren Hein.
See LICENSE and README.
*/
/// Left-hand opponent array: lho[hand] gives the hand sitting to hand's left.
/// Bridge hand positions: 0=North, 1=East, 2=South, 3=West (compass orientation)
/// From each player's perspective (compass direction):
/// North's left=East(1), East's left=South(2), South's left=West(3), West's left=North(0)
const int lho = ;
/// Right-hand opponent array: rho[hand] gives the hand sitting to hand's right.
/// Bridge hand positions: 0=North, 1=East, 2=South, 3=West (compass orientation)
/// From each player's perspective (compass direction):
/// North's right=West(3), East's right=North(0), South's right=East(1), West's right=South(2)
const int rho = ;
const int partner = ;
/// Bitmask representation of card ranks.
/// Maps absolute rank (2-14, plus sentinels) to bitmask for efficient
/// rank membership testing and operations. Index r holds 1 << (r-2).
const unsigned short bit_map_rank = ;
/// Text representation of card ranks for human-readable output.
/// Maps rank (0-15) to character: '2' through 'A', with sentinels 'x' and '-'.
const unsigned char card_rank = ;
/// Text representation of suits for human-readable output.
/// Maps suit (0-4) to character: S/H/D/C/N (Spades/Hearts/Diamonds/Clubs/NoTrump).
const unsigned char card_suit = ;
/// Text representation of hands for human-readable output.
/// Maps hand (0-3) to character: N/E/S/W (North/East/South/West).
const unsigned char card_hand = ;