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

Обсуждение задачи 1306. Медиана последовательности

Anyone have any ideas on what Test 8 is doing?
Послано SquidBoy 8 мар 2013 11:27
Had some issues implementing the heap, and then realised had a nice Access Violation (didn't bother to check we weren't exceeding the bounds on the heaps underlying array).

Now I'm stuck on Test #8 - but I've tried every test I've seen suggested in the comments....Anyone got a nice test to try ???
Re: Anyone have any ideas on what Test 8 is doing?
Послано SquidBoy 12 мар 2013 05:12
I've even tried generating up to about 190000 random numbers < 2^31-1 in Excel (3 columns) and my median always agrees with theirs....

I've Also tried the same number of ordered numbers (incrementing by 1) as well as random but sorted numbers in a single column (sorted in both directions).

I suspect I have some silly output issue (rather than a logic issue - but that might just be because I;m arrogant).
I think the admins might want to check the wording
Послано SquidBoy 12 мар 2013 05:41
Ok, for those who have trouble with test 8.  Apparently 0 is a valid value in the tests (I'd assumed that POSITIVE meant "strictly greater than 0" - I would have thought including 0 is NON-NEGATIVE rather than POSITIVE).  Once I catered for the possibility of 0 in the heap, everything was happy....
In my case
Послано josue.0 2 июл 2016 12:59
In my case I was getting wrong one of the elements for the semi-sum.