The largest product of numbers in a sequence#9535

The largest product of numbers in a sequence

1 second
64 megabytes
Hard

You are given a set of numbers. Your task is to find the maximum possible product that can be obtained by multiplying exactly numbers from this set.

Input

The first line contains two space-separated integers and , and the second line contains space-separated integers. 4 \leq n \leq 20, 3 \leq nmax < n. The values of the numbers are in the range .

Output

Print the maximum product that can be achieved by selecting exactly numbers from the given set.

Examples

Example 1

Loading
Loading