By the way, that is a great program. If I could only download it.....
Bitboard for chess engine help
Also by the way, the utility that I am currently using for bitboards is pretty good. Just google BLH2_win.rar and a chess2u page will come up. Is the program any good do you think?
Unsigned long long int myBitboard = 0;
myBitboard |= (1 >> 32); //this sets the 33rd bit to 1
myBitboard &= (0 >> 63); // sets 64th bit to 0
// the lines above creates an integer (number) variable which on the hardware is represented by 64 bits, each being either 1 or 0. The idea of bitboards is to have each bit represent a square on the board, or to store multiple smaller numbers inside a single int
unsigned long long int whitePawnsBB = 0;
For(int i=0; i<8; i++) {
whitePawnsBB |= 1 >> (7 + i);
}
What does the expression (0 >> 63) from your code snippet evaluate to? (hint: this is a trick question).
If you can answer this question correctly, you'll also why
myBitboard |= (1 >> 32); //this sets the 33rd bit to 1
doesn't do what you want.
Again my advice (to the OP, not to you): hands off of bitboards!
I know that most people say that bitboards are not for beginners, but I am a good learner and figure-outer. Not to override you, but I think I will stick with bitboards. I do not know that answer to your question, but then I don't think that you asked it to me.
Also, do you know of any C++ forums that I can post in without setting up an account?
Thanks to you all
I think that the answer to your first question (0>>63) means that you shift bits(I don't know how many) to the left.
In response to Quote #14, the main reason that I want bitboards is that using for loops is virtually unneeded in bitboards. What does the for loop in post #14 do?
In response to Quote #14, the main reason that I want bitboards is that using for loops is virtually unneeded in bitboards. What does the for loop in post #14 do?
HAhaha what
Bitboards don't let you avoid for loops. They let you think in terms of sets instead of piece lists.
If so, could you direct me in the use of bitboards, or lead me to an experienced forum or group?
Thank you all
Is there any way to download it? I would prefer not to have to go online every time I want to program( my everyday-use computer does not have internet connection). If not, I suppose I could use this tool that you showed me.
Thanks again!