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

I think I understand problem wrong, please help
Posted by Vasya 1 Mar 2005 20:35
We are asked to find x, that x*x-x delitsa na N, N-proizvedenie dvuh prostih 4isel. Gde i o6ibaus, WA na vtorom teste
Re: I think I understand problem wrong, please help
Posted by TECTOBOP 2 Mar 2005 18:11
Uslovie takoe.
WA na vtorom teste ni o chem ne govorit, poskol'ku vo vseh testah, krome pervogo, K = 1000.
Opishi svoj algoritm hot'a by.
Isn't it better to write in English for anyone to understand it? (-)
Posted by Dmitry 'Diman_YES' Kovalioff 2 Mar 2005 18:21
Re: Isn't it better to write in English for anyone to understand it? (-)
Posted by TECTOBOP 2 Mar 2005 19:11
Vasya said:
I think I understand problem wrong, please help. Did I understood [how is it in past?] problem description right?
I have WA on test 2.
I said:
You understood description well. WA#2 doesn't tell about anything, because in all tests besides first K = 1000. You'd better tell what algo you used.
My algorithm
Posted by Vasya 5 Mar 2005 04:18
My english is not very good
x(x-1) devides by n, n is a product of two distinct primes p and q, and there are two cases:1) x devides by p, (x-1) devides by q;2)  x devides by q, (x-1) devides by p;
WA on second test
maybe n can have another deviders, not only two:p and q?
Re: My algorithm
Posted by NOT 11 Apr 2005 00:20
maybe n can have another deviders, not only two:p and q?
for example:  n=30  (2*3*5)
Ansver = 0 1 6 10 15 16 21 25