ADMINS!!! WRONG TEST!!!
test #1
6
7 0 0 0 0 0
my program output "2\n1 2" but gets WA#1
You are wrong. The first test is the sample for all Timus Top Coders' problems (-)
Re: You are wrong. The first test is the sample for all Timus Top Coders' problems (-)
Послано
WA? 10 июн 2006 21:36
yes, you are right
my cheat program:
var N;
begin
readln(N);
readln(N);
readln(N);
if (N=0) then 10 div 0 else InfinityRecursion
end.
of course, read(N);
i can't undestand why WA
i am in despair. it work! test it!
at least once for sample input it write sample output.
i don't use any random, but it gets WA1
//code deleted
Edited by author 13.06.2006 23:27
Re: i can't undestand why WA
ht[heap[hp].nexN&0x7FF]=hp++; //It's wrong!
Re: i can't undestand why WA
ht[heap[hp].nexN&0x7FF]=hp++; //It's wrong!
why it's wrong?
it's equivalent line:
ht[heap[hp].nexN&0x7FF]=hp; hp++;
Re: i can't undestand why WA
ht[heap[hp].nexN&0x7FF]=hp; hp++; //It's right!
and after finding of all mistakes, you get the TLE#6...
Check the your program on these tests:
6
1 2 3 4 5 6
3
1 1 2
3
1 2049 4097
Edited by author 11.06.2006 05:08
Re: Check the your program on these tests:
я извиняюсь, мне просто не сказать этого по английски :)
я запостил не ту версию программы, в этой есть баги.
да не в этом дело
я написал программу которая даёт правильный ответ на sample#1
причём даже в той же последовательности выводит номера.
моя программа даёт ответ:
4
4 5 1 6
но проверяющая система выносит вердикт: WA#1
я закомментировал вывод ответа
и написал в конце printf("4\n4 5 1 6");
такая программа получает WA2
вопрос: как такое может быть, что одна программа
получает WA2, а вторая WA1
я не однократно проверил что программы на
этот sample выдают один и тот же ответ
может быть причина в том, что я вывожу числа так:
for (i=0;i<chetotam;i++) printf("%d ",int_ar[i]);
мешает лишний пробел? это глупо, и маловероятно.
перед выводом нет перевода строки.
больше мне ничего в голову не приходит
Re: Check the your program on these tests:
На всякий случай убери лишний пробел, моя АС прога не выводит его...
I will try to help you (+)
Your solution is verified by a checker written by Ilya Grebnov, and no one still claimed it works wrong. I want you to send me both you WA(1) and WA(2) solutions for investigation. If some bug in the checker is found I will fix it. My e-mail for Russian-speaking programmers is dimanyes@mail.ru
Re: Check the your program on these tests:
Your program works wrong on sample input. Test it with other compiler. For example, with Intel C++ Compiler 7.0
Re: Check the your program on these tests:
I have only Visual Studio 6 & 2005
in this IDE my program writes right answer
Re: I will try to help you (+)
sent. I write a new program - WA12 :)
Re: I will try to help you (+)
I send. You forgot about?
I did not forget. I just tried to understand why it works wrong (+)
I have nothing to say. Everything is ok on my Borland C++ Builder compiler. You must contact with Vladimir Yakovlev to investigate this problem because he is C++ programmer. I have forwarded your mail to him.
Re: I did not forget. I just tried to understand why it works wrong (+)
can you give me his e-mail?
you know my, sent it.
Re: Check the your program on these tests:
Послано
Wasdek 13 ноя 2013 20:04
I have same problem. On 1 test my program output:
4
6 1 5 4
but WA1. Why?