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

Обсуждение задачи 1418. Армейская история

WA 10
Послано HeypaBHoBeceH 26 фев 2009 09:39
Is there a trick? I must forget something, because i tried 3 different implementations for finding the current convex hull of the points, and all three get WA 10...
Re: WA 10
Послано Vedernikoff Sergey (HSE: EconomicsForever!) 26 фев 2009 18:29
What does you program output on the following test:
3
0 0
1 1
2 2

?
Re: WA 10
Послано HeypaBHoBeceH 26 фев 2009 23:55
Vedernikoff Sergey (HSE: EconomicsForever!) писал(a) 26 февраля 2009 18:29
What does you program output on the following test:
3
0 0
1 1
2 2

?

0
Re: WA 10
Послано Vedernikoff Sergey (HSE: EconomicsForever!) 27 фев 2009 00:03
It's ok. Try this:
8
0 0
0 1
0 2
1 0
1 2
2 0
2 1
2 2
Re: WA 10
Послано HeypaBHoBeceH 27 фев 2009 12:08
Vedernikoff Sergey (HSE: EconomicsForever!) писал(a) 27 февраля 2009 00:03
It's ok. Try this:
8
0 0
0 1
0 2
1 0
1 2
2 0
2 1
2 2
1 :)
Is there a chance, you looked at my code? It's not so long, and I'll put some comments. If you don't want to get involved, I'll understand :)
Re: WA 10
Послано Vedernikoff Sergey (HSE: EconomicsForever!) 27 фев 2009 14:58
Ok, send it to nick[youknowwhat]inbox[youknowwhatagain]ru, using goryinyich instead of nick
Re: WA 10
Послано HeypaBHoBeceH 27 фев 2009 17:18
message is sent, thank you in advance!
Re: WA 10
Послано Vedernikoff Sergey (HSE: EconomicsForever!) 28 фев 2009 02:43
Received. But I'll have time to look at it only in saturday-sunday...
Re: WA 10
Послано Vedernikoff Sergey (HSE: EconomicsForever!) 28 фев 2009 03:52
Your code gets WA on the following test:
33
1 1
2 2
3 3
4 4
5 5
6 6
7 7
8 8
9 9
10 10
11 11
-1 1
-2 2
-3 3
-4 4
-5 5
-6 6
-7 7
-8 8
-9 9
-10 10
-11 11
0 -1
0 -2
0 -3
0 -4
0 -5
0 -6
0 -7
0 -8
0 -9
0 -10
0 -11

By the way, even if you correct the error, it will get TLE: for the test generated by the following Pascal code you program doesn't finish the job in 1 minute:
var
  i, n: integer;
begin
  n := 1333;
  rewrite (output, 'input.txt');
  writeln (3*n);
  for i := 1 to n do
    writeln (i , ' ', i);
  for i := 1 to n do
    writeln (-i , ' ', i);
  for i := 1 to n do
    writeln (0 , ' ', -i);
end.
Re: WA 10
Послано HeypaBHoBeceH 1 мар 2009 03:24
AC atlast :) Thanks man, I had 2 big problems, but all fixed with +10 lines code. Thank you for great test!
Re: WA 10
Послано Andres 16 мар 2010 05:28
Hey how did you solve the TLE?
Re: WA 10
Послано Andres 16 мар 2010 06:22
nevermind.. .acos takes a looot of time