ГлавнаяСборникиТурнирыРазделыФорумыУчастникиПечатьПомощьО системе

Турниры > IMPC-2014-15 Questions > задача:


Ind_02-20. 50745 - Bitonic Sequence

IMPC-2014-15 Questions

Старт: 22.ноя.2014 в 15:00:00
Финиш: 22.ноя.2014 в 20:00:00
Турнир завершён!
• Турнирная таблица

Гость
• Вопросы к жюри (1)

Задачи турнира

• 4th-2. 50524 - Elevator
• 4th-3. 50535 - Image Compression
• 4th-6. 50536 - Epoka Furgon Shpk
• Ind_01-10. 50752 - Student Groups
• Ind_01-20. 50416 - Placing Domino...
• Ind_01-30. 50764 - Fast Typing Co...
• Ind_01-50. 50718 - Elevator
• Ind_02-10. 50497 - Falling Bricks - ...
• Ind_02-20. 50745 - Bitonic Seq...
• Ind_02-30. 50657 - Permutations an...
• Ind_03-10. 50743 - Total Scholarshi...
• Ind_03-20. 50515 - Lines - Revisited
• Ind_03-40. 50777 - Dwarfs Maze
• Ind_03-50. 50679 - Jetpack Hurdle J...
• Ind_04-10. 50787 - Expected Value
• Ind_04-20. 50520 - Filling a Matrix ...
• Ind_04-30. 50658 - The Message

Обратная связь

Если у вас есть предложения или пожелания по работе Contester, посетите форум сайта www.contester.ru.

Лимит времени 2000/4000/4000/4000 мс. Лимит памяти 65000/65000/65000/65000 Кб.
Question by Ibrahim Mesecan.

Bitonic Sequence

Question: Bitonic sequence is a sequence which first increases and then decreases. Write a program that reads a series of numbers. Then, by placing the biggest number to the middle, it converts this series into a bitonic sequence. Note that from the same series, there can be many sequences giving the bitonic property.

Input specification
You will be given an integer (n) where 0 ≤ n ≤ 10,000. Then, you will be given n integers where each of the numbers is less than 1e8.

Output specification
Place the biggest number to the middle of the list. Then, the first part of list will increase, and the second part will decrease.

Sample Input I
5
7 3 6
5 9
Sample Input II
10
19 11 3 5 9 0
4 7 9 18
Sample Output I
3 5 9 7 6
or, 3 6 9 7 5
both comply the bitonic
sequence property.
Sample Output II
0 4 7 11 18 19 9 9 5 3



Для отправки решений необходимо выполнить вход.

www.contester.ru