HomeVolumesContestsSectionsForumsUsersPrintHelpAbout

Sections > Geometry > problem:


50664 - Polygons

Guest
• Discussion of problem (2)

Section problems

• 50664 - Polygons
• 50263 - Points
• 50268 - Triangles
• 51041 - Plane Segmentation
• 50670 - Picture
• 50487 - Radius of Inscribed Circle
• 50480 - What quadrant is it?
• 50473 - Counting Circles Positions
• 50327 - Parallel Lines

Feedback

If you notice incorrect translations in Contester, please let author know.

Time limit 3000/4000/4000/4000 ms. Memory limit 65000/65000/65000/65000 Kb.
Автор: Кирилл Бутин, ПГУ.

You are given a convex polygon with N vertices. Find the total number of parts it is divided by all possible diagonals, assuming that no three of them intersect at one point.

Input
The first line of input contains one integer N (3 ≤ N ≤ 50000).

Output
Output a single number – the number of parts.

Input 1 Output 1
3
1
Input 2 Output 2
4
4

Для отправки решений необходимо выполнить вход.

www.contester.ru