Find all integers m such that $0 < m < 1008$ and $\gcd(m, 2016-m) = 1$.
The following is my solution:
Note that $1 = \gcd(m, 2016-m) = \gcd(m, 2016)$.
Since $2016$ is even and divisible by $3, 7, 9, 21, 63$ and $\gcd(m, 2016) = 1$, so $m$ is odd and $m\neq 3k, 7l$, where $k, l\in \mathbb Z,$ and $k, l$ are odd numbers.
Since $0 < m< 1008,$ we deduce that $1\leq k\leq 335, \ 1\leq l\leq 143$ and $k, l$ are odd.
We set $$A = \{3k|\ k\in\mathbb Z,\ 1\leq k\leq 335,\ k \mbox{ odd}\}$$ and $$B = \{7l|\ l\in\mathbb Z,\ 1\leq l\leq 143,\ l \mbox{ odd}\}.$$ Then, we have $|(A\cup B)\setminus (A\cap B)| = 168 + 72 - 48 = 192.$
On the other hand, from $1$ to $1008$ we have $\frac{1007-1}{2} + 1 = 504$ odd numbers. Combining these data, we conclude that there are $504 -192 -24 = 288$ positive integers $m$.