Prove that there are exactly
$$\displaystyle{\frac{(a-1)(b-1)}{2}}$$
positive integers that cannot be expressed in the form
$$ax\hspace{2pt}+\hspace{2pt}by$$
where $x$ and $y$ are non-negative integers, and $a, b$ are positive integers such that $\gcd(a,b) =1$.
Hints: Prove
If $ax+by=c$, and $ax'+by'=c$, then $b$ divides $x-x'$, and $a$ divides $y-y'$, and $(x-x')/b=(y'-y)/a$.
$n$ can be expressed if and only if $((a-1)(b-1)/2)-1-n$ can't.