Let $p$ and $n$ be positive integers such that $p$ is prime and $1 + np$ is a perfect square. Prove that the number $n + 1$ can be expressed as the sum of $p$ perfect squares, where some of them can be equal.
Source: 2003 Peru Cono Sur TST P2
Tags: number theory
Let $p$ and $n$ be positive integers such that $p$ is prime and $1 + np$ is a perfect square. Prove that the number $n + 1$ can be expressed as the sum of $p$ perfect squares, where some of them can be equal.