Factorial Squares
1. **Stating the problem:** We need to find all pairs of positive integers $(n,m)$ such that the sum of factorials from $1!$ to $n!$ equals a perfect square $m^2$, i.e.,
$$1! + 2! + 3! + \cdots + n! = m^2.$$
2. **Evaluate the sum for small values of $n$:** Factorials grow quickly, so let's check initial values:
- For $n=1$: sum $= 1! = 1$, which is $1^2$ (a perfect square), so $(n,m)=(1,1)$ works.
- For $n=2$: sum $= 1! + 2! = 1 + 2 = 3$, $3$ is not a perfect square.
- For $n=3$: sum $= 1 + 2 + 6 = 9$, $9 = 3^2$ is a perfect square, so $(3,3)$ works.
- For $n=4$: sum $= 9 + 24 = 33$, not a perfect square.
- For $n=5$: sum $= 33 + 120 = 153$, not a perfect square.
- For $n=6$: sum $= 153 + 720 = 873$, not a perfect square.
- For $n=7$: sum $= 873 + 5040 = 5913$, not a perfect square.
3. **Check the nature of sums for $n>3$:** Factorials grow very fast. The sum quickly becomes large numbers that are not close to perfect squares. Moreover, the difference between consecutive sums equals $(n+1)!$, which grows very quickly and does not follow a pattern that maintains a perfect square.
4. **Conclusion:** The only pairs $(n,m)$ that satisfy the equation are for $n=1$ and $n=3$; thus, the solutions are:
$$oxed{(1,1) \text{ and } (3,3)}.$$