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 1305. Convex Hull

Can somebody explain to me this problem?
Posted by Grebnov Ilya[Ivanovo SPU] 4 Sep 2004 16:53
What sequence of broken line’s vertexes  should print my program? Give me some hints or tests.
Of course, I can :) (+)
Posted by Dmitry 'Diman_YES' Kovalioff 4 Sep 2004 21:21
Just find a convex octagon of minimal area which satisfyes the following conditions:

- all the points given are inside it or lay on it's borders
- it's 2 sides are parallel to oX (-)
- it's 2 sides are parallel to oY (|)
- it's 2 sides are 45 degrees to oX (/)
- it's 2 sides are -45 degrees to oX (\)

And then output all the vertices of this figure. There could be 8 vertices, but some of them might be the same (some sides has zero length), so output them only once. So your output is from 1 till 8 vertices.

Very easy statistical solution is O(N) time, O(1) memory.

P.S. I will answer any your question - just mail me.
Re: Of course, I can :) (+)
Posted by chhung6 2 Jul 2010 01:08
I can only understand the problem statement after reading this thread...

Thanks so much!
Little correction
Posted by Hikmat Ahmedov 12 Mar 2013 16:48
Dmitry 'Diman_YES' Kovalioff wrote 4 September 2004 21:21
Just find a convex octagon of minimal area

Area should not be minimal, the number of points inside convex polygon should be minimal, in other words, try so that more points lie on the boundary rather than inside the polygon.