Solution
= Solution
<Maximum a posteriori decoding> chooses an input with the largest posterior probability given the received word. By Bayes' theorem this maximizes $P(X=x)p(y\mid x)$ over candidate codewords, minimizing the average probability of a decoding error.