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

Обсуждение задачи 1070. Местное время

Показать все сообщения Спрятать все сообщения

Stupid problem... Clarification must be included in problem description!!! Alexey Chernenkov (Deprecated) 18 июл 2011 21:45
Why if there is no answer, we should print "5"? It must be included in problem description!!!
Not 5, but we should add 30 minutes to difference we seek for. For instance, we've found "2H=9", what is unbelievable, 'cause it contradict the statement. But I increment this to get the even number 10=2*5. Answer: 5 hours.
I still don't know why is it true.

Update. I've just found my mistake. The tests are OK (but method of "increment" also works).

Edited by author 07.08.2011 16:57
I not used any equations. I bruteforced through all possible differences, and if answer was not found then I was printing "5" (by advices from forum).
Problem description is correct.
Try this test:
01.01 21.59
04.23 09.22

Answer:4
But I think your solution will print 5 because of this condition.
So people who got AC for this problem using this condition solved it incorrectly.

Edited by author 23.10.2013 01:14

Edited by author 23.10.2013 01:14
I also tried bruteforce and on test 2 my program finds that there is no valid answer.
However, if I just return 5 in case of failure program gets acc. I'd really like to know what test 2 is.


By the way, my program outputs the correct answer on the test above.
kittylover писал(a) 23 октября 2013 01:14
Try this test:
01.01 21.59
04.23 09.22

Answer:4