Can you move from one side being checked to other side in stalemate? I am not a chess player but I have a homework where I have to code a chess program. I would like to know if it is possible for a player's piece to be in check, the player to move out of check, and in turn put the other player in a stalemate, from just one move?
For example: White is in check -&gt; White moves out of check -&gt; Black is stalemated
I haven't found any examples of it so far, but I also haven't found anything saying it's never possible, so if anyone can say either way that would be great!
It's possible, e.g.
[FEN &quot;2Q4k/2R4b/8/8/8/8/K7/8 b - - 0 1&quot;]

1...Bg8+
2. Ka3?? 1/2-1/2