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 1078. Segments

optimization
Posted by Sushil Nath 29 Jun 2011 02:14
how you people are getting 0.001
Though I have used nlog(2*MAX_X) solution I am getting around 0.015 to 0.031
My approach :
1 . Make all coordinates > 0 and xi = MAX_X - x1+1
2 . process the points in increasing y and for same y increasing x
3 . maintain BIT [0..MAX_X] and do query and update in log
Re: optimization
Posted by bsu.mmf.team 2 Jul 2011 18:39
The 0.015 is the minimal allowed time now. The peoples, who attend 0.001 have sent there solutions later.
*sorry for my bad english