知两边求三边.py 211 B

12345678
  1. import math
  2. a,b,theta = input().split()
  3. a = float(a)
  4. b = float(b)
  5. theta = float(theta)
  6. theta_radians = math.radians(theta)
  7. c = math.sqrt(a**2 + b**2 - 2*a*b*math.cos(theta_radians))
  8. print("c = {:.4f}".format(c))