CALCAREA - Calculate the Area

no tags 

Very simple. You are given polygon and you need to calculate his area. The polygon does not self intersect

Input

A lonely integer N (3 <= N <= 10000) - the number of nodes. On each of the next N lines you will find the coordinates of the next vertex from the polygon.

Output

A single integer - the rounded up area of the polygon.

Example

Input:
4
0 0
1 0
1 1
0 1

Output:
1

hide comments
matheuslealv: 2017-05-24 13:36:01

Is it a convex polygon ?

Last edit: 2017-05-24 13:38:30

Added by:Nikola P Borisov
Date:2008-11-24
Time limit:1s
Source limit:50000B
Memory limit:1536MB
Cluster: Cube (Intel G860)
Languages:All except: ERL JS-RHINO NODEJS PERL6 VB.NET