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

Обсуждение задачи 1645. Лыжная гонка

i don't understand why?
Послано Rustam 25 окт 2008 16:27
could you explain me test and answer? i can't understand how this situation may happen
Re: i don't understand why?
Послано Rustam 27 окт 2008 21:56
finally i understood the problem. solution is much easier than it's problem.
the problem's solution is very easy:
to find min: min[i] = i -count of a[j] where{j<i and a[j]>a[i]}
to find max: max[i] = n -count of a[j] where{j>i and a[j]>a[i]}
good luck!
Re: i don't understand why?
Послано svr 27 окт 2008 22:10
Much more harger and so important is to prove the result.
Re: i don't understand why?
Послано Crusader 28 окт 2008 08:14
here is my solution, i don't know why it is not correct and i always wa at #6

lowest:

min[i] = count of a[j] where{j>i and a[j]<a[i]} + 1

highest:

max[i] = n - count of a[j] where{j<i and a[j]>a[i]}

i need some help, thx.

Edited by author 28.10.2008 08:15
Re: i don't understand why?
Послано Oleg Strekalovsky [Vologda SPU] 3 май 2009 15:45
Rustam писал(a) 27 октября 2008 21:56
finally i understood the problem. solution is much easier than it's problem.
the problem's solution is very easy:
to find min: min[i] = i -count of a[j] where{j<i and a[j]>a[i]}
to find max: max[i] = n -count of a[j] where{j>i and a[j]>a[i]}
good luck!
I think there are some mistakes in your code.
For other: Don't look at this code. Think yourself (As I) :)
Re: i don't understand why?
Послано Pegasus 18 дек 2012 15:57
You are right,that anwer got Wa6