← All problemsSign in

Polygon with N-Sides

You have given an integer $N$. A Regular Polygon is an $N-sided$ Polygon in which all the sides are of the same length and are symmetrically placed about a common center (i.e. the polygon is both equiangular and equilateral). Examples- Equilateral Triangle, Square, Pentagon, Hexagon, Heptagon, Octagon and so on. Your task is to find the Number of Lines that can be formed inside the Regular $N-s

HINT LADDERno hints yet
L1 Observation
L2 Technique
L3 Approach
L4 Pseudo-code
🔒
L5 Full solution
L5 unlocks only if you insist twice
solution.cppC++17

CodeSearch Tutor

Hints, not spoilers — it won’t hand over the full solution unless you insist.

voice by Sarvam AI

Sign in to chat with the tutor and save your progress.

Sign in to start