Solution (source code)

= Solution

Choose \b[$|\psi_0\rangle=|+\rangle$] and its <orthogonal> companion $|\psi_1\rangle=|-\rangle$. Since $X|+\rangle=|+\rangle$, either branch of `RandomFlip` returns the same <pure state>. Alice therefore obtains label 0 with certainty, and
$$
\boxed{\Pr(1\mid\texttt{RandomFlip})=0.}
$$
The alternative choice $|-\rangle$ also works: its sign change under $X$ is only a <global phase>. The useful property is being a <Pauli eigenstate> of the <Pauli X gate>.