human
Write me a code to check if an N and the other steps required given the following:
Check if an N | Function to check if the polygon exists or not.
Initialize a variable to store the sum of angles.
Loop through the array and calculate the sum of angles.
Check the condition for an N - side polygon.
Driver Code.
Given array arr [ ].
Function Call"
Solution in Python:
assistant
#Here is code to check if an N and the other steps required.
 def checkValidPolygon ( arr , N ) :
	Sum = 0
	for i in range ( N ) :
		Sum += arr [ i ]
	if Sum == 180 * ( N - 2 ) :
		print ( " Yes " )
	else :
		print ( " No " )
N = 3
arr = [ 60 , 60 , 60 ]
checkValidPolygon ( arr , N )