[dba-Tech] Questions about 2 Unusual Databases

Arthur Fuller artful at rogers.com
Sat Nov 6 10:32:41 CST 2004


Rocky Smolin - Beach Access Software wrote:

> Arthur:
>
> I might use an array of 32 bytes where each byte represents a square 
> on the board and the contents of that byte describes the piece , if 
> any, occupying that square.
>
> If you want to get into bit twiddling, it could probably be done in 
> less than 32 bytes.  There are 6 different pieces, yes, pawn, rook, 
> knight, bishop, queen, king.  and two colors. So it seems that the 
> numbers 1 through 12 could represent all the pieces of both colors.
>
> Rocky
>
Nice compaction, but perhaps a little too nice. How to represent 64 
squares in 32 bytes, according to your formula? In addition, I'm not 
quite sure how your proposed scheme would handle an ambiguous move. A 
simple example (not to argue its strategic merits!)... Using old 
notation because it's easier to visualize:

W:  P to QB4
B: P to K4
W: P to K4
B: P to Q4

At this point W could take the P at Q4 using either P.




More information about the dba-Tech mailing list