Given that $2^{1234566} ≡ 899557 \pmod {1 234 567}$, is the number $1234567$ composite or prime?
The FlT says that if $p$ is prime and doesn't divide $a$, then $a^{p-1} \equiv 1 \pmod p$.
This is a statement of the form $P \implies Q$. If this is true, then the contrapositive is also true, $\neg Q \implies \neg P$.
The contrapositive here states that if $a^{p-1} \not \equiv 1 \pmod p$ then ($p$ is not prime or $p$ divides $a$).
We have that $a^{p-1} \not \equiv 1 \pmod p$, but $p \not \mid a$, and so it must be the case that $p$ is not prime.