Point In Polygon

hard
https://cses.fi/problemset/task/2192

Input Format

Check Link

Output Format

Check Link

Constraints

Check Link

Example

Input
4 3
1 1
4 2
3 5
1 4
2 3
3 1
1 3
Output
INSIDE
OUTSIDE
BOUNDARY
Previous
Polygon Area
Next
Polygon Lattice Points

Related Questions