#K65082. Maximum Product of Two
Maximum Product of Two
Maximum Product of Two
Given a list of integers, you are required to determine the maximum product of any two distinct elements from the list. The list may contain both positive and negative integers. Remember that the product of two negative numbers could yield a large positive number, which might be the maximum product.
Note: The list will always contain at least two numbers.
inputFormat
The first line of input contains an integer n representing the number of elements in the array. The second line contains n space-separated integers.
outputFormat
Output a single integer which is the maximum product of any two distinct elements in the array.
## sample5
3 4 5 2 1
20