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 1120. Sum of Sequential Numbers

Haha. I'll AC this problem :D
Posted by homealone1 27 Mar 2015 11:56
O(sqrt(2 * N))
I have:
A = (2 * N - P * P + P ) / ( 2 * P )
and P = [1, 2, 3, ..., sqrt(2 * N) + 3] :D
I got AC ...