练28.1 多边形内角和
You cannot submit for this problem because the contest is ended. You can click "Open in Problem Set" to view this problem in normal mode.
Description
In Euclidean geometry, the sum of interior angles of an n-sided polygon is (n-2)×180°.
Given (n-1) interior angles of an n-sided polygon, write a program to calculate the remaining unknown interior angle.
Input Format
The first line contains a single integer n (3≤n≤20).
The second line contains (n-1) positive integers representing the known interior angles, separated by spaces. The input guarantees that the polygon is valid.
Output Format
Output a single positive integer representing the unknown interior angle.
Sample
3
45 6075
20251101B班作业(5)
- Status
- Done
- Problem
- 4
- Open Since
- 2025-11-1 0:00
- Deadline
- 2025-11-9 23:59
- Extension
- 24 hour(s)