Answers.Body: <p>For this kind of questions, if you have doubts, just play chess with the goal of capturing the enemy king. The first player to capture the enemy king wins. This isn't the official rule, but it's effectively the same in almost all situations I'm aware of (it doesn't work for stalemate).</p>
  <p>So after 1...Qxe8+, White wins with 2. Nxa8. It doesn't matter that Black also threatens to capture White's king with 2...Qxe1, since White has already won.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2022-03-05T13:04:29.253Z
Answers.Text: Thank you, do you know the official rule?
Answers.UserDisplayName: Weather Vane
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2022-03-05T13:16:22.807Z
Answers.Text: @WeatherVane pretty sure the official rule is "you may not make a move that leaves your king in check".
Answers.UserDisplayName: Allure
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2022-03-05T15:15:47.520Z
Answers.Text: [Rules of Chess dealing with checks and leaving your King in check](https://en.wikipedia.org/wiki/Rules_of_chess#Check)
Answers.UserDisplayName: SecretAgentMan
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2022-03-05T21:14:35.533Z
Answers.Text: For completeness, it's not effectively the same because stalemate exists.
Answers.UserDisplayName: RemcoGerlich
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2022-03-05T12:09:27.487Z
Answers.LastActivityDate: 2022-03-06T00:32:49.343Z
Answers.LastEditDate: 2022-03-06T00:32:49.343Z
Answers.UserDisplayName: Allure
Answers.Body: <p>A legal way to get into the same kind of situation:</p>
  <p><a href="https://i.sstatic.net/bOPsd.png" rel="noreferrer"><img src="https://i.sstatic.net/bOPsd.png" alt="enter image description here" /></a>
  <a href="https://i.sstatic.net/a9JTU.png" rel="noreferrer"><img src="https://i.sstatic.net/a9JTU.png" alt="enter image description here" /></a></p>
  <p>But as others have posted: <a href="https://en.wikipedia.org/wiki/Rules_of_chess#Check" rel="noreferrer">It is illegal to make a move that places or leaves one's king in check.</a></p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2022-03-05T18:59:41.200Z
Answers.Text: Exactly.  Black has no move after **1. Rc8#**. The game is over.
Answers.UserDisplayName: SecretAgentMan
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2022-03-05T17:43:00.770Z
Answers.LastActivityDate: 2022-03-05T17:45:39.337Z
Answers.LastEditDate: 2022-03-05T17:45:39.337Z
Answers.UserDisplayName: Velvet
Answers.Body: <p><strong>Not</strong> allowed, no.</p>
  <p>White gives two checks (hence double), and meeting one isn't enough.
  After blacks reply Qxe8+, blacks king is still in check which makes Qxe8+ an illegal move.</p>
  <p>Black is thus <strong>checkmated</strong> in your position.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2022-03-05T11:16:21.893Z
Answers.Text: A similar question on [Quora](https://www.quora.com/Suppose-in-chess-my-king-got-checked-but-at-the-same-time-I-have-the-opportunity-to-check-my-opponents-king-Now-both-of-our-kings-are-checked-Would-the-game-end-in-a-draw-or-would-this-be-illegal) (I don't have an account) says *"... It may be possible to play a move that blocks the attack on your King while giving check to the opponent's King, but it is very seldom you'll have the opportunity to do that..."*
Answers.UserDisplayName: Weather Vane
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2022-03-05T23:48:40.267Z
Answers.Text: @WeatherVane that's possible in single check situations but not double checks. If your king is being attacked by another piece after you make your move, that's an illegal move.
Answers.UserDisplayName: llama
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2022-03-06T00:20:12.070Z
Answers.Text: @WeatherVane: If it helps, you can think of it as "whoever captures the enemy king first wins" (we just end the game before that actually happens). In your second image above, it's white's turn so he can play Nxa8 before black can play Qxe1.
Answers.UserDisplayName: BlueRaja - Danny Pflughoeft
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2022-03-06T02:15:00.480Z
Answers.Text: Is there a move (in other double checks, not the above one) that blocks *both* checks, *and* puts the opponent in check? That would be very "call an ambulance... but not for me".
Answers.UserDisplayName: stevec
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2022-03-06T03:04:44.167Z
Answers.Text: @stevec that could be another question, but it's not possible to *block* a double check because if the checks are blockable, they have to be along different directions (pick two of rank, file, diagonal) so one square can't block both. It's pretty easy to construct something where you move out of double check and put the opponent in check though: Rd4+ for white here would be bad for that reason https://lichess.org/analysis/8/8/1r1k3K/8/5R2/6B1/8/8_w_-_-_0_1#0
Answers.UserDisplayName: llama
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2022-03-06T03:07:26.490Z
Answers.Text: @llama nice, I thought that might be the case, but in chess, I never rule anything out without checking, as there is often some crazy exception that proves the initial hypothesis incorrect. Thanks for confirming.
Answers.UserDisplayName: stevec
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2022-03-05T11:05:36.110Z
Answers.LastActivityDate: 2022-03-05T11:05:36.110Z
Answers.UserDisplayName: starrin
Body: <p>Escaping a double check</p>
  <p>The answer to <a href="https://chess.stackexchange.com/questions/25053/is-it-possible-to-block-a-double-check">Is it possible to block a double check?</a> says</p>
  <blockquote>
  <p>Moving the king is the only way to escape a double check. There is no possible other move that will block both checks.</p>
  </blockquote>
  <p>But in the following situation, is it allowed for Black to escape by taking the Rook (placing White in check) and forcing a sacrifice of the Queen? If not, why not?</p>
  <p>Black to move. Never mind how it got to this position, it's for illustration.</p>
  <p><a href="https://i.sstatic.net/BsRm7.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/BsRm7.png" alt="enter image description here" /></a></p>
  
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2022-03-05T12:56:39.050Z
Comments.Text: "Never mind how it got to this position, it's for illustration" -- a bit too glib. You position doesn't work, but if it did it would be irrelevant since there is no legal way that it could arise.
Comments.UserDisplayName: John Coleman
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2022-03-05T13:03:14.990Z
Comments.Text: @JohnColeman I am interested in getting out of such a position, not unhelpful comments restating what I already put.
Comments.UserDisplayName: Weather Vane
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2022-03-05T13:06:51.817Z
Comments.Text: The point of my comment is that when trying to understand the rules of chess, it isn't helpful to wonder how they apply to positions which can never arise. When crafting a position, why not do the extra work to make sure that it can arise via a legal sequence of moves?
Comments.UserDisplayName: John Coleman
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2022-03-05T13:17:31.443Z
Comments.Text: @JohnColeman a double-check *can arise*. I apologise for offending your sensibilities. I could have made a better example, but isn't recommended to change a question after answers have been posted which would invalidate them. I'll heed your advice next time.
Comments.UserDisplayName: Weather Vane
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2022-03-05T14:38:05.333Z
Comments.Text: Is the starting position legal?  Looks like it requires an illegal move to reach. From the first position, Black is **checkmated** and does not get a move.
Comments.UserDisplayName: SecretAgentMan
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2022-03-05T15:17:17.550Z
Comments.Text: @SecretAgentMan thanks for your valuable input, please read the preceding comments, which cover it nicely.
Comments.UserDisplayName: Weather Vane
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2022-03-05T17:32:58.743Z
Comments.Text: For future visitors, this question could be greatly improved by using a valid position. The OP's current 3 position sequence is illegal.
Comments.UserDisplayName: SecretAgentMan
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2022-03-05T23:43:04.430Z
Comments.Text: Here's a legal double check position which I think represents the situation you want to cover, sidestepping this issue: https://lichess.org/editor/1k4q1/pp6/N7/8/8/6B1/8/6K1_b_-_-_0_1
Comments.UserDisplayName: llama
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2022-03-06T00:26:59.003Z
Comments.Text: @llama thanks but it isn't quite, because the Queen can't be taken after taking the bishop. I thought the question was simple enough but I'll give some more explanation. It's not *supposed* to be a real game. It's about a coding challenge, where the given position might be anything, the incorrect number of pieces, or an invalid position (possible responses) but the moves are standard. That's what I am solving, and I wanted to make sure this really is an inescapable checkmate. I didn't expect to be murdered, or have revenge downvoting elsewhere.
Comments.UserDisplayName: Weather Vane
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2022-03-06T00:55:02.360Z
Comments.Text: "*I didn't expect to be murdered*" seems needlessly hyperbolic.  If downvoting elsewhere is happening because of your question, that is not right.  Your question is fine to me.  The original question contained no context about "coding" and naturally caused some confusing regarding legal moves.
Comments.UserDisplayName: SecretAgentMan
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2022-03-06T05:15:15.180Z
Comments.Text: An important thing to remember when thinking about chess situations: if you capture the opposing king, you win.
Comments.UserDisplayName: Mark
Tags: <rules><check><double-check>
Title: Escaping a double check
ThreadText: # Escaping a double check
  
  (Asked by: username_0 on 2022-03-05)
  
  Escaping a double check
  
  The answer to [Is it possible to block a double check?](https://chess.stackexchange.com/questions/25053/is-it-possible-to-block-a-double-check) says
  
  > Moving the king is the only way to escape a double check. There is no possible other move that will block both checks.
  
  But in the following situation, is it allowed for Black to escape by taking the Rook (placing White in check) and forcing a sacrifice of the Queen? If not, why not?
  
  Black to move. Never mind how it got to this position, it's for illustration.
  
  [![enter image description here](https://i.sstatic.net/BsRm7.png)](https://i.sstatic.net/BsRm7.png)
  
  **Tags:** rules, check, double-check
  
  > **Comments:**
  > **username_1**: "Never mind how it got to this position, it's for illustration" -- a bit too glib. You position doesn't work, but if it did it would be irrelevant since there is no legal way that it could arise.  
  > **username_0**: @JohnColeman I am interested in getting out of such a position, not unhelpful comments restating what I already put.  
  > **username_1**: The point of my comment is that when trying to understand the rules of chess, it isn't helpful to wonder how they apply to positions which can never arise. When crafting a position, why not do the extra work to make sure that it can arise via a legal sequence of moves?  
  > **username_0**: @JohnColeman a double-check *can arise*. I apologise for offending your sensibilities. I could have made a better example, but isn't recommended to change a question after answers have been posted which would invalidate them. I'll heed your advice next time.  
  > **username_2**: Is the starting position legal?  Looks like it requires an illegal move to reach. From the first position, Black is **checkmated** and does not get a move.  
  > **username_0**: @username_2 thanks for your valuable input, please read the preceding comments, which cover it nicely.  
  > **username_2**: For future visitors, this question could be greatly improved by using a valid position. The OP's current 3 position sequence is illegal.  
  > **username_3**: Here's a legal double check position which I think represents the situation you want to cover, sidestepping this issue: https://lichess.org/editor/1k4q1/pp6/N7/8/8/6B1/8/6K1_b_-_-_0_1  
  > **username_0**: @username_3 thanks but it isn't quite, because the Queen can't be taken after taking the bishop. I thought the question was simple enough but I'll give some more explanation. It's not *supposed* to be a real game. It's about a coding challenge, where the given position might be anything, the incorrect number of pieces, or an invalid position (possible responses) but the moves are standard. That's what I am solving, and I wanted to make sure this really is an inescapable checkmate. I didn't expect to be murdered, or have revenge downvoting elsewhere.  
  > **username_2**: "*I didn't expect to be murdered*" seems needlessly hyperbolic.  If downvoting elsewhere is happening because of your question, that is not right.  Your question is fine to me.  The original question contained no context about "coding" and naturally caused some confusing regarding legal moves.  
  > **username_4**: An important thing to remember when thinking about chess situations: if you capture the opposing king, you win.  
  
  ---
  
  ## 3 answers
  
  ### Answer by username_8 on 2022-03-05. Score: 8 | Accepted answer
  
  **Not** allowed, no.
  
  White gives two checks (hence double), and meeting one isn't enough.
  After blacks reply Qxe8+, blacks king is still in check which makes Qxe8+ an illegal move.
  
  Black is thus **checkmated** in your position.
  
  > **Comments:**
  > **username_0**: A similar question on [Quora](https://www.quora.com/Suppose-in-chess-my-king-got-checked-but-at-the-same-time-I-have-the-opportunity-to-check-my-opponents-king-Now-both-of-our-kings-are-checked-Would-the-game-end-in-a-draw-or-would-this-be-illegal) (I don't have an account) says *"... It may be possible to play a move that blocks the attack on your King while giving check to the opponent's King, but it is very seldom you'll have the opportunity to do that..."*  
  > **username_3**: @WeatherVane that's possible in single check situations but not double checks. If your king is being attacked by another piece after you make your move, that's an illegal move.  
  > **username_9**: @WeatherVane: If it helps, you can think of it as "whoever captures the enemy king first wins" (we just end the game before that actually happens). In your second image above, it's white's turn so he can play Nxa8 before black can play Qxe1.  
  > **username_10**: Is there a move (in other double checks, not the above one) that blocks *both* checks, *and* puts the opponent in check? That would be very "call an ambulance... but not for me".  
  > **username_3**: @username_10 that could be another question, but it's not possible to *block* a double check because if the checks are blockable, they have to be along different directions (pick two of rank, file, diagonal) so one square can't block both. It's pretty easy to construct something where you move out of double check and put the opponent in check though: Rd4+ for white here would be bad for that reason https://lichess.org/analysis/8/8/1r1k3K/8/5R2/6B1/8/8_w_-_-_0_1#0  
  > **username_10**: @username_3 nice, I thought that might be the case, but in chess, I never rule anything out without checking, as there is often some crazy exception that proves the initial hypothesis incorrect. Thanks for confirming.  
  
  ---
  
  ### Answer by username_5 on 2022-03-05. Score: 8
  
  For this kind of questions, if you have doubts, just play chess with the goal of capturing the enemy king. The first player to capture the enemy king wins. This isn't the official rule, but it's effectively the same in almost all situations I'm aware of (it doesn't work for stalemate).
  
  So after 1...Qxe8+, White wins with 2. Nxa8. It doesn't matter that Black also threatens to capture White's king with 2...Qxe1, since White has already won.
  
  > **Comments:**
  > **username_0**: Thank you, do you know the official rule?  
  > **username_5**: @WeatherVane pretty sure the official rule is "you may not make a move that leaves your king in check".  
  > **username_2**: [Rules of Chess dealing with checks and leaving your King in check](https://en.wikipedia.org/wiki/Rules_of_chess#Check)  
  > **username_6**: For completeness, it's not effectively the same because stalemate exists.  
  
  ---
  
  ### Answer by username_7 on 2022-03-05. Score: 6
  
  A legal way to get into the same kind of situation:
  
  [![enter image description here](https://i.sstatic.net/bOPsd.png)](https://i.sstatic.net/bOPsd.png)
  [![enter image description here](https://i.sstatic.net/a9JTU.png)](https://i.sstatic.net/a9JTU.png)
  
  But as others have posted: [It is illegal to make a move that places or leaves one's king in check.](https://en.wikipedia.org/wiki/Rules_of_chess#Check)
  
  > **Comments:**
  > **username_2**: Exactly.  Black has no move after **1. Rc8#**. The game is over.  
  
  ---
  
  