Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
First solution in Clear category for The Angles of a Triangle by PawlakBartosz43
import math
def checkio(a, b, c):
if a + b <= c or a + c <= b or b + c <= a:
return [0, 0, 0]
alpha = round(math.degrees(math.acos((a**2 + b**2 - c**2)/(2*a*b))))
beta = round(math.degrees(math.acos((b**2 + c**2 - a**2)/(2*b*c))))
delta = round(math.degrees(math.acos((c**2 + a**2 - b**2)/(2*a*c))))
list = [alpha, beta, delta]
list.sort()
return list
Jan. 15, 2017