# Cardboard Mountains AK_74u National Girls' Programmi...

There are n coordinates. The area of the shape using those n coordinates according to the statement. The given figure shows what it may look like. The area of the purple polygon will be output.

Here, these things should be observed,

1. A point $p_i$ is considered left to $p_j$ if $x_{p_i}.

2. A point $p_i$ is considered right to $p_j$ if $x_{p_i}>x_{p_j}$.

3. There can be multiple coordinates with the same $x$-value. In this case, only considering the coordinate with the maximum $y$-value is to be considered as it will cover all the coordinates below while creating the shape.

While calculating area, The intersecting point of two adjacent triangles’ sides is to be found out. Then the area can be easily calculated using the shoelace theorem or triangle area or any other method. The implementation is up to the solvers.

Analysis and solutions: link to repository. Geometry

### Statistics

100% Solution Ratio
tanzim_bnEarliest, 4M ago
Sk_SabitFastest, 0.1s
Sk_SabitLightest, 13 MB
tanzim_bnShortest, 843B 