Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
First solution in Uncategorized category for The Angles of a Triangle by UFO665
import math
def angle(a, b, c):
return int(round(math.degrees(math.acos((a * a + b * b - c * c) / float(2 * a * b)))))
def checkio(a, b, c):
if all(s for s in [a + b > c, a + c > b, b + c > a]):
alpha = angle(a, b, c)
beta = angle(b, c, a)
gamma = 180 - alpha - beta
return sorted([alpha, beta, gamma])
return [0, 0, 0]
Dec. 14, 2015