Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

How to prove that the number $1!+2!+3!+...+n! \ \forall n \geq 4$ is never square?

I was told to count permutations but I cannot figure out what we are permuting.... Thanks!

share|cite|improve this question
My apologies, for n>3 – Adam L. Apr 19 '11 at 18:16

The first few cases are easily dealt with: $1!=1$ and $1!+2!+3!=9$ are squares, while $1!+2!=3$ is not.

For $n \ge 4$, $1!+2!+3!+ \ldots + n!$ is congruent to 3 mod 5. But all squares are congruent to 0, 1, or 4 mod 5.

share|cite|improve this answer
Or in simpler terms, a perfect square never ends in 3 (i.e talking mod 10 instead of mod 5). – Aryabhata Apr 19 '11 at 18:11

Firstly, it's only true for n > 3. Secondly, I don't see how to do it with permutations.

But the key is to consider residue classes mod 10. $ 1! + 2! + ... + n! $ is congruent to either 3 or 8 mod 10, but no square ends in either 3 or 8.

share|cite|improve this answer
Oh, it was already answered! – mixedmath Apr 19 '11 at 18:25
It is always $3$, never $8$, when $n>3$, isn't it? – Jonas Meyer May 31 '12 at 19:05

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.