Feedback | If you notice incorrect translations in Contester, please let author know.
|
|
Time limit 2000/4000/4000/4000 ms. Memory limit 65000/65000/65000/65000 Kb.
Given N integers. You are asked to choose two of them such that whose product is maximum.
Input
Firstly, N - the number of numbers in sequence (2 <= N <= 100). Further, the sequence is written: N of integers which are less than 1000.
Output
Bring out the two unknown numbers in any order.
If there are several different pairs of numbers that give
the maximum product, then bring out any of them.
input 1
Td>
|
Input 2
Td> tr> |
9
3 5 1 7 9 0 9 -3 10
|
3
-5 -300 -12
Td> tr> |
Output 1 b>
Td>
|
Output 2 b>
Td> tr>
9 10
Td>
|
-300 -12
Td> | |
Для отправки решений необходимо выполнить вход.
|