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

Обсуждение задачи 1010. Дискретная функция

To admin: about the testdata of this problem.
Послано CleverKid 7 фев 2003 16:15
I tried so many ACed program but all of them can't AC again.
Please make sure if the testdata is still correct.
Thank you!
HI CK (CleverKid :P)! online contest
Послано Locomotive 7 фев 2003 19:30
Hi CK
i didnt think about 1010 alreay...
but i have solved 1036 with so fast time
dont u want to come to talking about it? (a hard challenge:P)
and also
an online contest in USA: (it has only 3day remain time)
   http://ace.delos.com/contestgate
i wish it be useful 4 u
Any1 who get AC help us...
Послано Locomotive 7 фев 2003 20:30
> I tried so many ACed program but all of them can't AC again.
> Please make sure if the testdata is still correct.
> Thank you!
Any1 who get AC help us... (answer these questions)
Послано Locomotive 7 фев 2003 20:34
Should output be K,K+1???
should we use abs function during calculating the inclination???
Is Ranges Right???
I had test all ways and at all i got WA
I agree CK that test cases are incorrect
Var
  n,i,m:longint
  x,y                 :extended;
  ans                 :extended;
begin
  ans:=0; ---------> or even 0-maxint! alls are incorrect!
  m:=1;
  readln(n);
  readln(x);
  for i:=2 to n do
  begin
    y:=x;
    readln(x);
      if x-y>ans then  -------> or abs??? (both cases WA:( )
      begin
        ans:=x-y;
        m:=i-1;
      end;
  end;
  writeln(m,' ',m+1);
end.
Check your mail:)
Послано CleverKid 7 фев 2003 21:25
> Hi CK
> i didnt think about 1010 alreay...
> but i have solved 1036 with so fast time
> dont u want to come to talking about it? (a hard challenge:P)
> and also
> an online contest in USA: (it has only 3day remain time)
>    http://ace.delos.com/contestgate
> i wish it be useful 4 u
This problem is so easy (+)
Послано Dmitry 'Diman_YES' Kovalioff 8 фев 2003 17:48
The algo is O(N). You are only to find number i (2<=i<=N) such as abs
(f[i]-f[i-1]) is maximal and then to output i-1 and i.
Good luck!
Have you tried to submit your program again??Maybe you will get WA.....
Послано CleverKid 8 фев 2003 22:09
> The algo is O(N). You are only to find number i (2<=i<=N) such as
abs
> (f[i]-f[i-1]) is maximal and then to output i-1 and i.
> Good luck!
So strange! Now it's WA, but solution is obviously correct. Maybe you should wait some days (-)
Послано Dmitry 'Diman_YES' Kovalioff 9 фев 2003 18:22
I had the same troubles with another problem
Послано Agh 10 фев 2003 13:51
I tried to pass 1174 some days earlier and got WA, but because i'm
sure that it's OK i send it today (nothing changing in code) and
recieve AC
But I Still Get WA
Послано Locomotive 10 фев 2003 18:10
CleverKis sent me his Code and he (or she) Said that it will got AC
but as her (or him) was such as mine
Still WA :(
I dont know why why why???
WA too
Послано wangchen1ren 14 фев 2003 22:37
> CleverKis sent me his Code and he (or she) Said that it will got
AC
> but as her (or him) was such as mine
> Still WA :(
> I dont know why why why???
Re: This problem is so easy (+)
Послано Sergey 23 фев 2003 00:40
I used the same algo. Here is the program. Either the tests are
incorrect, or we dont know something :-) A puzzle.
Maybe I am wrong after all?

Var
 maxpoint,i,N : integer;
 y,max,X : extended;
begin
   readln(N);
   readln(y);
   readln(x);
   max:=abs(x-y);
   maxpoint:=1;

   For i:=3 to n  do
    begin
      y:=x;
      readln(x);
      if abs(x-y) > max then begin max:= abs(x-y); maxpoint:=i-1;end;
    end;

    Write(maxpoint,' ', maxpoint + 1);
end.
Check this test:)))
Послано Valentin Mihov 25 фев 2003 18:08
3


1


-2000000000


2000000000
Re: Check this test:)))
Послано Sergey 6 мар 2003 20:51
And what the answer should be?
 2 3 ?
Re: To admin: about the testdata of this problem.
Послано Cancer 16 мар 2003 17:47
ME TOO
WHY