0
$\begingroup$

This question already has an answer here:

An exercise at the end of a chapter on primitive roots asked me to compute $1^k + 2^k + \ldots + (p-1)^k \pmod{p}$ for any positive integer $k$ and any prime $p$. Clearly, if $k$ is odd, the expression is congruent to $0$ modulo $p$. But how can I even approach this problem if $k$ is even? And how do primitive roots apply? Hints would be greatly appreciated.

$\endgroup$

marked as duplicate by Stefan4024, Jack D'Aurizio number-theory Aug 9 '18 at 23:12

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

0
$\begingroup$

apply Fermat's little theorem it says

$a^p \equiv \pmod p$

If $p-1 \mid k$ then by Fermat Little Theorem $a^k \equiv 1 \pmod p$

$\endgroup$
  • $\begingroup$ I don't see this. The exponents in the sum are $k$, not $p.$ $\endgroup$ – saulspatz Aug 9 '18 at 23:03
  • $\begingroup$ sorry I made a mistake $\endgroup$ – Deepesh Meena Aug 9 '18 at 23:03

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