1556 - Calculating Area
Time Limit : 1 Second
Memory Limit : 128 MB
Submission: 186
Solved: 55
- Description
- This problem is very straightforward, in a 2-D plane, Give you a polygen, you need calculate its area.
- Input
- One integer T indicates the number of test cases
Each case is started with one integer n which means the number of points of that polygen then n lines followed, each line is a pair of real number x y describe the x-coordinate and y-coordinate of point, points are descriped counter clockwise.
- Output
- One real number rounded up to 2 decimal indicates the area of polygen.
- sample input
-
2 4 0 0 1 0 1 1 0 1 3 0 0 1 0 1 1
- sample output
-
1.00 0.50
- hint
- source
- The 6th ACM Programming Contest of HUST