Describe
In Euclidean geometry, the inner angle of the N-edged shape is (n-2) *180°. Given the degrees of the inner angles (n-1), it is possible to calculate the degree of the remaining unknown inner angle. Please write a program to solve this problem.
Enter line 1th with only one integer n (2<n<1000), which is the number of sides of the polygon.
The 2nd line has (n-1) a positive integer, which is the degree of each known inner angle. Adjacent two integers are separated by a single space.
Data guarantees that a given polygon is valid. Outputs a positive integer that is the degree of the unknown inner angle. Sample input
345 60
Sample output
75
1#include <iostream>2#include <cstdio>3 using namespacestd;4 intMain ()5 {6 inta,x,b;7 //double x;8Cin>>A;9B= (A-2)* the;Ten for(intI=0; i<a-1; i++) One { ACin>>x; -b-=x; - } theprintf"%d", B); - return 0; -}
The cyclic basis of programming basis-polygon inner angle and;