QOJ.ac

QOJ

Time Limit: 1 s Memory Limit: 32 MB Total points: 10

#11186. Diamond [B]

Statistics

Jack works as a jeweler. A beautiful diamond of extraordinary size has been shipped to his shop. There are two customers who would like to buy it, so Jack decided to cut the diamond into two pieces (not necessarily of equal masses) and sell each piece to one of the customers.

Diamonds are very hard and can only be cut by a saw with diamond blades. The cutting process is expensive and slow, as it takes about an hour to cut two millimeters. Jack can only afford making one cut along a single plane. Both pieces which he will receive are to be sold to the two customers.

Jack would like to make his customers as happy as possible. As the total mass of the pieces will obviously be equal to the mass of the whole diamond, Jack has decided to maximize the total number of faces in the two pieces. He does not know how to cut the diamond in such a way, so he asked you for help.

Input Format

In the first line of the standard input there is a single integer $n$ ($4 ≤ n ≤ 80$), the number of vertices of the diamond. Each of the following $n$ lines contains three integers $x_{i}$, $y_{i}$, $z_{i}$ ($-360 ≤ x_{i}, y_{i}, z_{i} ≤ 360$), separated by single spaces, and representing coordinates of the $i^{\text{th}}$ vertex of the diamond. The diamond is the smallest convex polyhedron, that contains all given vertices. None of those points lie in the interior the diamond and no four vertices are located in the same plane.

Output Format

The first and only line of the standard output should contain one integer - the largest total number of faces of the two pieces obtained by cutting the diamond once only.

Example

Input

5
0 0 0
5 0 0
0 5 0
0 0 5
2 2 2

Output

14
About Issues

We understand that our problem archive is not perfect. If you find any issues with the problem, including the statement, scoring configuration, time/memory limits, test cases, etc.

You may use this form to submit an issue regarding the problem. A problem moderator will review your issue and proceed it properly.

STOP! Before you submit an issue, please READ the following guidelines:

  1. This is not a place to publish a discussion, editorial, or requests to debug your code. Your issue will only be visible by you and problem moderators. Other users will not be able to view or reply your issues.
  2. Do not submit duplicated issues. If you have already submitted one, please wait for an moderator to review it. Submitting multiple issues will not speed up the review process and might cause your account to be banned.
  3. Issues must be filed in English or Chinese only.
  4. Be sure your issue is related to this problem. If you need to submit an issue regarding another problem, contest, category, etc., you should submit it to the corresponding page.

Active Issues 0

No issues in this category.

Closed/Resolved Issues 0

No issues in this category.