Raymond B. answered 08/20/21
Math, microeconomics or criminal justice
P(X/~A)P(~A) = P(~A/X)P(X)
P(X) = P(X/~A)P(~A)/P(~A/X) = (1/2)(1)/(1) = 1/2
It's very similar to Monty Hall's 3 curtain paradox
though. If the guard is like Monty and selects only an inmate who is not being executed, it's like Monty selecting only a curtain with no prize. That means P(X) = 1/3, not 1/2. But if the guard just randomly checked and told X that A is not being executed, P(X) = 1/2
There's also a "Sleeping Beauty" paradox where you can use the same Bayes Theorem equations.
Oddly mathematicians seem certain Monty Hall's paradox's solution is switch curtains when Monty gives you a clue. While a virtual similar paradox with Sleeping Beauty there is no consensus, just a very heated argument with sides certain they're right.