Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: Basic bitboard representation in C (shifting)

Author: Michael Diosi

Date: 11:06:06 01/06/06

Go up one level in this thread



Hi,

maybe like this ?

typedef unsigned long long BitBoard;// linux
typedef unsigned __int64 BitBoard;// windows
const BitBoard A1 = 0x0000000000000001;
 where
const BitBoard H8 = 0x8000000000000000;
 some compilers might like the numebr expressed  this way:
const BitBoard A1 = 0x0000000000000001ULL;
const BitBoard H8 = 0x8000000000000000ULL;

Best,
Michael


 frogMeSebastian wrote:

>Put the pawn on A2 if you like to. It's just an example.
>
>Perhaps let me clarify my question:
>What datatype needs to be used for a 64-bit bitboard (long long int?) and how
>would I manually (within the sourcecode) assign some (made-up) bitboard to it.
>Do I need to use the octal number system for that?



This page took 0 seconds to execute

Last modified: Thu, 15 Apr 21 08:11:13 -0700

Current Computer Chess Club Forums at Talkchess. This site by Sean Mintz.