Find all the triples of integers $(a, b, c)$ such that the number

$$
N=\frac{(a-b)(b-c)(c-a)}{2}+2
$$

is a power of 2016.

(A power of 2016 is an integer of the form $2016^{n}$, where $n$ is a non-negative integer.)
Let $a, b, c$ be integers and $n$ be a positive integer such that

$$
(a-b)(b-c)(c-a)+4=2 \cdot 2016^{n}
$$

We set $a-b=-x, b-c=-y$ and we rewrite the equation as

$$
x y(x+y)+4=2 \cdot 2016^{n}
$$

If $n>0$, then the right hand side is divisible by 7, so we have that

$$
x y(x+y)+4 \equiv 0 \quad(\bmod 7)
$$

or

$$
3 x y(x+y) \equiv 2 \quad(\bmod 7)
$$

or

$$
(x+y)^{3}-x^{3}-y^{3} \equiv 2 \quad(\bmod 7)
$$

Note that, by Fermat's Little Theorem, for any integer $k$ the cubic residues are $k^{3} \equiv-1,0,1$ $(\bmod 7)$.

It follows that in (1) some of $(x+y)^{3}, x^{3}$ and $y^{3}$ should be divisible by 7.

But in this case, $x y(x+y)$ is divisible by 7 and this is a contradiction.

So, the only possibility is to have $n=0$ and consequently, $x y(x+y)+4=2$, or, equivalently, $x y(x+y)=-2$.

The solutions for this are $(x, y) \in\{(-1,-1),(2,-1),(-1,2)\}$,

so the required triples are $(a, b, c)=(k+2, k+1, k), k \in \mathbb{Z}$, and all their cyclic permutations. (9)

Alternative version: If $n>0$ then 9 divides $(a-b)(b-c)(c-a)+4$, that is, the equation $x y(x+y)+4 \equiv 0(\bmod 9))$ has the solution $x=b-a, y=c-b$.

But then $x$ and $y$ have to be 1 modulo 3, implying $x y(x+y) \equiv 2(\bmod 9)$, which is a contradiction.

We can continue now as in the first version.