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 1403. Courier

Show all messages Hide all messages

O(n^2) is the best way or not? hoan 26 Dec 2010 20:01
No. I solved in in O(nlogn)
Can you explain me your algo?
thanks in advance.
Re: O(n^2) is the best way or not? phizaz 14 Apr 2013 22:54
I think you have to use binary tree to implement something.
Re: O(n^2) is the best way or not? Andrew Sboev [USU] 14 Apr 2013 23:04
Binary tree? Are you kidding? just quick sorting of array and little thinking.

Edited by author 14.04.2013 23:05