Hi everybody

First of all thank you for your time and your response.

I encountered the following issue:

sm=Sum( n^s % p, {n,1,p-2} )

(Where % = modulo, p is prime, s is a positive integer)

Is there any proof thats shows:

sm % p= 0for odds

sm % p= -1for evens

sm % p = -2fors = k(p-1)wherekany integer greater than1

If there is plz tell me

I give you the mathematica commands,

I used for this issue:

p = 11

s = 8

sm = 0

Do[{f = Mod[n^s, p], sm = sm + f}, {n, 1, p - 2}]

Mod[sm, p]

Thank you again