Well, the question is so:
Suppose P is the set of all primes, p, that satisfy the condition that $8^p+15^p$ is a perfect square.
Find the sum of the elements of P.
Now, over here, I found out a few bits of information. However, I've no idea how to use them, and whether they can even be used.
For example, it should be obvious that 2 belongs to P. As $64+225 = 289 = 17^2$ Also,
$15\equiv -8 \pmod{23}$ So, for all primes greater than 2, (which are obviously odd)
$8^p+ 15^p\equiv 8^p+ (-8)^p\equiv 8^p-8^p \equiv 0 \pmod{23}$
Suppose $8^p+15^p = x^2$, then, $x^2 \equiv 0 \pmod{23}$,
And, as 23 is a prime, this means that, $x \equiv 0 \pmod{23}$ and $x^2 \equiv 0 \pmod{23^2}$.
I also found out that,
$8^p +15^p \equiv 8^{p-(p-1)}+15^{p-(p-1)} \pmod{p}$, by Euler's Theorem.
Therefore,
$x^2\equiv 8^p+15^p \equiv 8+15 \equiv 23 \pmod{p}$.
Hmm. I'd really appreciate it if, instead of giving me a solution flat out, someone could point me in the right direction and perhaps offer a slight push.
Thanks a lot, people.