Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: The programmer could ask 2 questions (not 7) for en passant.

Author: Jonathan Lee

Date: 16:52:52 02/15/00

Go up one level in this thread


Any programmer could ask the following questions for en passant:
0.  Who moves first?

1.  (White to move first) If there is a black pawn on the 5th rank, then ask:
    "Is en passant an option"?
If no, then don't ask number 2.

If yes, then:
2.  Which black pawn was moved 2 spaces?
    The person will press letters a,b,c,d,e,f,g, or h.

If "g" was pressed, then computer will check for:
    a.)  black pawn on g5
    b.)  at least a white pawn on f5 and/or h5
    c.)  squares g6 and g7 are vacated

Therefore 6 questions can be asked for ambiguity, not neccessarily 11.
"There is more than one way to skin a cat."
Jonathan (23rd message)



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.