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

Обсуждение задачи 1642. Одномерный лабиринт

what if in one way we can reach , but on opposite way we can't?
Послано A.Z 25 окт 2008 13:57
for example , what's the output for this test?
input:
0 1

Re: what if in one way we can reach , but on opposite way we can't?
Послано Vladimir Yakovlev (USU) 25 окт 2008 14:06
Problem statements have been updated. One sentence was missed in English version. Sorry for inconvenience.
Re: what if in one way we can reach , but on opposite way we can't?
Послано Quryazov 25 окт 2008 14:07
in first sample,
when input is
3 -2
-10 -4 2
 then
output is
6 2
what is "2" in output?
Re: what if in one way we can reach , but on opposite way we can't?
Послано RedRick[TSOGU] 25 окт 2008 14:17
WA at Test 3? why??????!!!!
Re: what if in one way we can reach , but on opposite way we can't?
Послано ENick(TNU) 25 окт 2008 14:22
Why in test 1 answer is "6 2"???Correct answer is "4 2"
Re: what if in one way we can reach , but on opposite way we can't?
Послано Elmurod 25 окт 2008 21:45
Because He begin walk from 0 to 2 and from 2 to -2 so calculate it and you'll take 6 not 4;
-10 ... -4 .. -2 -1 0 1 2

m = 0;
from 0 to 1 m = 1;
from 1 to 2 m = 2;
from 2 to 1 m = 3;
from 1 to 0 m = 4;
from 0 to -1 m =5;
from -1 to -2(exit) m = 6;
n = 0;
from 0 to -1 n = 1;
from 0 to -2 n = 2;
answer 6 2
so did you understand?
Re: what if in one way we can reach , but on opposite way we can't?
Послано Jumabek_Alihonov 20 окт 2011 21:18
thanks i understand.
can you give me some test for problems

Edited by author 20.10.2011 21:19

Edited by author 20.10.2011 21:19