# Quickie #12

• Jan 15th 2007, 12:17 PM
Soroban
Quickie #12
For what $n$ is $\sum^n_{k=1} k!$ a square?

• Jan 15th 2007, 12:41 PM
AfterShock
Quote:

Originally Posted by Soroban
For what $n$ is $\sum^n_{k=1} k!$ a square?

Certainly for 1, 3, although for all n in general I'd start by using the fact

n^2 = summation(2k-1, k = 1...n)

and go from there.
• Jan 15th 2007, 12:47 PM
anthmoo
I have a feeling 20 is one...
• Jan 15th 2007, 12:50 PM
AfterShock
Quote:

Originally Posted by anthmoo
I have a feeling 20 is one...

No, 20 is not one. I checked with Maple.

You end up with 33sqrt(2.3519995354562*10^15)
• Jan 16th 2007, 11:25 AM
Soroban
Hello, AfterShock!

You found the only two solutions . . .

Note that squares must end in: $0,\,1,\,4,\,5,\,6,\,9$

List the first few sums:

$\begin{array}{cccc} 1! & = & \boxed{1}\\ 1!+2! & = & 3\\ 1!+ 2!+3! & = & \boxed{9}\\ 1!+2!+3!+4! & = & 33\end{array}$

Since $5!,\,6!,\,7!,\,\hdots$ all end in $0$,
. . all subsequent sums will end in $3$
. . and hence cannot be squares.

Therefore: $n = 1,\,3$ are the only solutions.