#1165: Puzzle Games

Source: Internet
Author: User
Describe

Fragrance today is in a good mood, and the flowers in the field of insects play a puzzle game.
This game is like this, for an array A, fragrance Select a number a from a, insects select a number b from a. A and B can be the same. Their score is the number of a*b factors.
The delicate fragrance and the worm of course want to get as high a score as possible, can you tell them which two number to choose?
Since the fragrance is a very casual person, the elements in array A are randomly chosen by her.

Input

A row of number N, which represents the number of integers in a.
The next line of N is the number of A1,A2,..., an, respectively, as an element of a.

n <= 100000, 1 <= ai <= 100000
Ensure that all AI are randomly generated.

Output

A row represents the maximum score.

Sample input
23 4
Sample output
6

#1165: Puzzle Games

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.