Problem 2270 Two Triangles

TimeLimit:1000MS  MemoryLimit:32MB
64-bit integer IO format:%I64d
未提交 | 登录后收藏
Problem Description

Fat brother and Maze are playing a kind of special (hentai) game with some points in a two-dimensional plane. First Fat Brother would choose three different points and then Maze would choose other three different points. If both of the player’s points form a triangle, they would feel happy. Also, if these two triangles are exactly the same, they would feel even happier. The two triangles are considered the same if one can be changed from another by translation and rotation.

Now given N points in a plane, Fat Brother would like to know how many different sets of points they can choose in order to make them even happier.

Input

The first line of the data is an integer T (1 <= T <= 100), which is the number of the text cases.

Then T cases follow, each case contains an integer N (6 <= N <= 10) indicated the number of the points in the two-dimensional plane. The N lines follow, each line contains two integers x and y (0 <= x, y <= 10) shows this point’s coordinate. All the points have different coordinate in this plane.

Output

For each case, output the case number first, and then output the number of the different sets of points they can choose in order to make them even happier.

SampleInput
3
6
0 0
2 0
2 1
8 8
10 8
10 9
6
0 0
2 0
2 1
8 8
10 8
10 7
6
0 0
1 0
2 0
0 1
1 1
2 1
SampleOutput
Case 1: 2
Case 2: 0
Case 3: 6
Submit
题目统计信息详细
总AC数0
通过人数0
尝试人数0
总提交量0
AC率0.00%
AC该题后可以添加标签
贴完标签可以获得20ACB。
并且可以获得本题所有提交代码查看权限。
点击标题可以显示标签。
如果你还没认真思考过这题,请不要查看标签
如果您已经通过了该题,请务为该题贴上标签

T^T Online Judge

[BUG反馈] [FAQ] [闽ICP备17026590号-1]
当前版本:3.24 系统时间: