1272: Triangle

内存限制:128 MB 时间限制:3.000 S
评测方式:文本比较 命题人:
提交:3 解决:0

题目描述

Given n distinct points on a plane, your task is to find the triangle that have the maximum area, whose vertices are from the given points.

输入

The input consists of several test cases. The first line of each test case contains an integer n, indicating the number of points on the plane. Each of the following n lines contains two integer xi and yi, indicating the ith points. The last line of the input is an integer −1, indicating the end of input, which should not be processed. You may assume that 1 <= n <= 50000 and −104 <= xi, yi <= 104 for all i = 1 . . . n.

输出

For each test case, print a line containing the maximum area, which contains two digits after the decimal point. You may assume that there is always an answer which is greater than zero.

样例输入 复制

3
3 4
2 6
2 7
5
2 6
3 9
2 0
8 0
6 5
-1

样例输出 复制

0.50
27.00