ENG  RUSTimus Online Judge
Online Judge
Problems
Authors
Online contests
About Online Judge
Frequently asked questions
Site news
Webboard
Links
Problem set
Submit solution
Judge status
Guide
Register
Update your info
Authors ranklist
Current contest
Scheduled contests
Past contests
Rules
back to board

Discussion of Problem 1204. Idempotents

Can anybody help me with P1204?If so,please send message to "flyingbluecat@hotmail.com".
Posted by Blue cat 19 Mar 2002 14:18
Re: Can anybody help me with P1204?If so,please send message to "flyingbluecat@hotmail.com".
Posted by Yuan 19 Mar 2002 15:25
because
  x*x=x (mod pq)
so
  x*x=kpq+x
  x(x-1)=kpq

p, q are distinct prime, so

case 1
  p|x, q|x-1
case 2
  p|x-1, q|x

for the first case, we have
pa=x, qb=x-1, so pa-qb=1
...