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

Обсуждение задачи 1004. Экскурсия

WA1 - is important order path?
Послано Wojciech Wawrzyniak 18 фев 2005 20:41
I have got many WA but I'don't know why .. I test my program and compare output test with CEOI1999 and have only one difference .. My find sometimes no the same path.  not for example 23 54 56 34  but 56 34 23 54 ... this can be reason for WA?
No subject
Послано Wojciech Wawrzyniak 20 фев 2005 02:53
I was change my program and i get the same results that OUT in CEIO1999 test any one can help me same advise?.
Re: WA1 - is important order path?
Послано The Big Bad Wolf (Cristina Stancu-Mara) 9 мар 2005 14:50
it's important the path..
in this problem you have to output the crossing points of the shortest sightseeing in the order how to pass them.
for your example if the route is 23 54 56 34 it's wrong to output 56 34 23 54 because you jump from a crossing point to another even if there is no road between them..
check the output for the CEOI problem with this one and see if there is any difference..
Re: WA1 - is important order path?
Послано Superthinker 13 мар 2005 19:20
I don't understand.
If the input is:
---------------------
3 2
1 2 1
2 3 1
3 2
1 2 1
2 3 1
1 3 1
-1
---------------------

Isn't the output like this?
---------------------
No solution.
3 1 2
---------------------

Help, please.
Re: WA1 - is important order path?
Послано Wojciech Wawrzyniak 5 апр 2005 20:29
Ok but if I have sightseeing :23 54 56 34 this is a cycle right? so 56 34 23 54 is the same cycle but it's only start from another point.

I didn't try to sending solution from one month perhaps now i'll find source of problem :)
Re: WA1 - is important order path?
Послано Sasko Vuckov 1 фев 2007 17:45
WA1 - is important order path?
- NO
Re: WA1 - is important order path?
Послано .Net, Java - any pcode sucks 21 апр 2007 02:46
NO, the first vertex of cycle does not matter.

My program prints sample out in such way:
2 5 3 1

And I got AC
Re: WA1 - is important order path?
Послано Smielov Valery 4 май 2007 00:20
try to do test use this program:

var fout:text;
    i:integer;
begin
 assign(fout,'test1004.in'); rewrite(fout);
 writeln(fout,'100 101');
 writeln(fout,'1 20 20');
 for i:=1 to 99 do
  writeln(fout,i,' ',i+1,' 1');
 writeln(fout,'100 1 1');
 writeln(fout,-1) ;
 close(fout);
end.

It real help me.
Re: WA1 - is important order path?
Послано Fessmax 6 мар 2009 21:37
My program prints sample out:
3 5 2 1
No solution.

And I got WA test 1

Edited by author 06.03.2009 21:37
Re: WA1 - is important order path?
Послано Kwc-Oliver 5 июн 2010 15:18
Thank you very much!!The answer is too long,I have to use
 ansistring in pascal.

But unfortunately I was wrong agian.