Number of triangulations

You are given a polygon with n sides without self-intersections. In how
many ways can you triangulate it?

Input

Input consists of several cases with only integer numbers. Each case
begins with n, followed by the n coordinates x y of the vertices given
in counterclockwise order. Assume 3 ≤ n ≤ 200 and |x|, |y| ≤ 10⁶. The
given polygons are such that no triangulation contains a degenerate
triangle.

Output

For every case, print the number of triangulations modulo 10⁹ + 7.

Problem information

Author: Gerard Orriols

Generation: 2026-01-25T11:18:35.924Z

© Jutge.org, 2006–2026.
https://jutge.org
