For , convexity of on gives
Consequently
For , independence and concavity of yield
The Chernoff bound therefore gives, for ,
For , the minimizer satisfies
Substitution gives the binary relative entropy
The endpoint cases follow by continuity.
Put . The same calculation, followed by , gives
Thus
The supplied lower bound implies
which proves the second upper-tail estimate. If , the event is empty and the same bound remains true.
For the lower tail, apply the exponential-moment argument with , or equivalently optimize at . It gives
Finally,
for , yielding ; the case follows by a limit.