Computer Chess Club Archives


Search

Terms

Messages

Subject: Simple C questions.

Author: TEERAPONG TOVIRAT

Date: 00:18:11 06/26/99


My program uses single array board like TSCP. In the generate movelist  function
I
use a lot of if , while statements to check whether it goes outside the board
such as
     if (piece(i-5)==EMPTY) add move;
My question is  do I have to check i is more than 4 ?   What would the compiler
return if it is piece[-1] or less?    Is this is a potential bug?
Thanks for any help,
Regards,
Teerapong



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.