ENG  RUSTimus Online Judge
Online Judge
Задачи
Авторы
Соревнования
О системе
Часто задаваемые вопросы
Новости сайта
Форум
Ссылки
Архив задач
Отправить на проверку
Состояние проверки
Руководство
Регистрация
Исправить данные
Рейтинг авторов
Текущее соревнование
Расписание
Прошедшие соревнования
Правила
вернуться в форум

Обсуждение задачи 1058. Шоколад

At last I have solved it!!! There is my solution
Послано Виктор (marilyn_manson@bk.ru) 21 июн 2004 21:38
My decision:

1.) We consider polygon such what it is, we spend 2 straight linees in parallel OX, one passes through the lowermost point, another through the uppermost. We spend a third - a line of a break on middle between a theme to two. We look at fragments. If the area of the top fragment is more, then we lift a line of a break on 1/4 all intervals, else is lowered. Then shift on 1/8 etc. To put it briefly, binary search we find height of a horizontal that it divided into equal fragments.

2.) We turn a figure, concerning any fixed point on a small corner (about 0.01 radian)

3.) We carry out action number 1.


And so we shall consider all possible variants. Certainly sooner or later it is necessary to stop to rotate a figure. It at turn on 180 degrees from an initial arrangement of a figure.

My decision works for 0.078 seconds and 253 Kb.

What your thunk about it?


GOOD LUCK!

I am sorry for bad English
Hm-m-m (+)
Послано Dmitry 'Diman_YES' Kovalioff 21 июн 2004 22:21
My solution differs from yours one, but I think your idea is interesting. I've solved it in a classical way using 2 binary searches - the first one inside the second, and then just a constants optimization...
Re: Hm-m-m (+)
Послано Виктор (marilyn_manson@bk.ru) 21 июн 2004 23:02
Thank for good words :-)
Can you explain your method for me? You know my email.

Edited by author 21.06.2004 23:05
Re: Hm-m-m (+)
Послано Denis Koshman 20 авг 2008 20:13


Edited by author 20.08.2008 20:22
Hm-hm-hm
Послано Dmitry "Logam" Kobelev [TSOGU] 9 янв 2009 00:41
I used similar idea and checked 10000 angles, but had wa10. Then I replaced it into 1000 and got AC. Now i'm wonder why, it seems to me accuracy lowered then.