Wilson’s Theorem states that $p$ is prime if and only if
$$(p-1)! \equiv -1 \pmod{19}$$
Problem (Estonia, 2000)
Prove that it is not possible to divide any set of $18$ consecutive positive integers into two disjoint sets $A$ and $B$, such that the product of the elements in $A$ equals the product of the elements in $B$.
Solution
Let $x_1$, $x_2$, …, $x_{18}$ be any $18$ consecutive integers and let us assume the mentioned division exists. Let $p(X)$ denote the product of the elements of the set $X$. Notice that among any $18$ consecutive integers, there is at most one multiple of $19$.
Case 1: one of the numbers is a multiple of $19$.
Let this number belong to the set $A$. Therefore
$$ p(A) \equiv 0 \pmod{19} $$
However, $B$ has no multiples of $19$ and
$$ p(B) \not\equiv 0 \pmod{19} $$
and $p(A) \neq p(B)$. Contradiction.
Case 2: none of the numbers is a multiple of $19$.
Therefore they give remainders $1$, $2$, …, $18$ modulo $19$. Since $19$ is prime, then by Wilson’s Theorem
$$ 18! \equiv -1 \pmod{19} $$
If $p(A) = p(B)$, then
$$ \left( p(A) \right)^2 = p(A) \cdot p(B) \equiv 18! \equiv -1 \pmod{19} $$
This means that a square of some integer gives remainder $-1$ modulo $19$. It is not hard to check that a square modulo $19$ is never $-1$. Contradiction.