3 ms·
It is very easy to implement with code. Chess computers are some of the first well-known computer programs (see, for example, Deep Blue). What is difficult is
by cmeacham98 4y ago
It is very easy to implement with code. Chess computers are some of the first well-known computer programs (see, for example, Deep Blue).
What is difficult is adapting chess's rules to this analog environment. It would be similarly difficult if you played this way with a real chess set in the real world, has nothing to do with code.
- ummonk 4y agoYou don't actually have infinitely many moves available in analog chess since you can only click on a pixel. But while check should be doable in reasonable time, checkmate / stalemate would be expensive to compute since you have to check every possible move of yours (not just with the king, but with other pieces that could interpose as well) and then check every possible opponent's move in response to each of your moves to see if the king will be in check in the resulting positions.
- cmeacham98 4y agoYou'll find that with some applied math you do not need to check every single possible move of the King.
- ummonk 4y agoPlease elaborate.