Solution (source code)

= Solution

<Independence> gives $P(X=Y)=\sum_rp_rq_r=\mathbb E_p[2^{\log_2q_X}]$. The given exponential convexity inequality therefore yields
$$
P(X=Y)\ge2^{\sum_rp_r\log_2q_r}=2^{-H(X)-D(p,q)}.
$$
Taking complementary probabilities proves
$$
\boxed{P(X\ne Y)\le1-2^{-H(X)-D(p,q)}}.
$$
The strict positivity of the entries of $q$ makes all logarithms appearing in this finite expectation well defined.