Buggy python submission (verdict: Runtime Error):
import math
tan, tyou, hour, minute = input()
tan_rad = 30 * hour + 0.5 * minute
tyou_rad = 6 * minute
if tan_rad == tyon_rad:
  answer = abs(tyou - tan)
elif abs(tan_rad - tyon_rad) == 180:
  answer = tyou + tan
else:
  rad = abs(tan_rad - tyou_rad)
  if rad > 180:
    rad = 360 - rad
  answer = math.sqrt((tan ** 2) + (tyou ** 2) - 2 * tan * tyou * math.cos(rad))
print(answer)

Fixed submission:
import math
ji, hun, H, M = input().split()
ji = int(ji)
hun = int(hun)
H = int(H)
M = int(M)
ji_rad = 30 * H + 0.5 * M
hun_rad = 6 * M
diff = abs(ji_rad - hun_rad)
if diff == 0:
  answer = abs(ji - hun)
elif diff == 180:
  answer = ji + hun
else:
  if diff > 180:
      diff = abs(360 - diff)
  answer = math.sqrt((ji ** 2) + (hun ** 2) - 2 * ji * hun * math.cos(math.radians(diff)))
print(answer)

Buggy python submission (verdict: Runtime Error):
import math
tan, tyou, hour, minute = input()
tan_rad = 30 * hour + 0.5 * minute
tyou_rad = 6 * minute
if tan_rad == tyon_rad:
  answer = abs(tyou - tan)
else:
  rad = abs(tan_rad - tyou_rad)
  if rad > 180:
    rad = 360 - rad
  answer = math.sqrt((tan ** 2) + (tyou ** 2) - 2 * tan * tyou * math.cos(rad))
print(answer)

Fixed submission:
import math
ji, hun, H, M = input().split()
ji = int(ji)
hun = int(hun)
H = int(H)
M = int(M)
ji_rad = 30 * H + 0.5 * M
hun_rad = 6 * M
diff = abs(ji_rad - hun_rad)
if diff == 0:
  answer = abs(ji - hun)
elif diff == 180:
  answer = ji + hun
else:
  if diff > 180:
      diff = abs(360 - diff)
  answer = math.sqrt((ji ** 2) + (hun ** 2) - 2 * ji * hun * math.cos(math.radians(diff)))
print(answer)

Buggy python submission (verdict: Runtime Error):
import math
tan, tyou, hour, minute = input()
tan_rad = 30 * hour + 0.5 * minute
tyou_rad = 6 * minute
if tan_rad == tyon_rad:
  answer = abs(tyou - tan)
else:
  rad = abs(tan_rad - tyou_rad)
if rad:
  answer = math.sqrt((tan ** 2) + (tyou ** 2) - 2 * tan * tyou * math.cos(rad))
print(answer)

Fixed submission:
import math
ji, hun, H, M = input().split()
ji = int(ji)
hun = int(hun)
H = int(H)
M = int(M)
ji_rad = 30 * H + 0.5 * M
hun_rad = 6 * M
diff = abs(ji_rad - hun_rad)
if diff == 0:
  answer = abs(ji - hun)
elif diff == 180:
  answer = ji + hun
else:
  if diff > 180:
      diff = abs(360 - diff)
  answer = math.sqrt((ji ** 2) + (hun ** 2) - 2 * ji * hun * math.cos(math.radians(diff)))
print(answer)

Buggy python submission (verdict: Runtime Error):
import math
tan, tyou, hour, minute = input()
tan_rad = 30 * hour + 0.5 * minute
tyou_rad = 6 * minute
if tan_rad == tyon_rad:
  answer = abs(tyou - tan)
else:
  rad = abs(tan_rad - tyou_rad)
if rad:
  answer = math.sqrt((tan ** 2) + (tyou ** 2) - 2 * tan * tyou * math.cos(math.radius(rad)))
print(answer)

Fixed submission:
import math
ji, hun, H, M = input().split()
ji = int(ji)
hun = int(hun)
H = int(H)
M = int(M)
ji_rad = 30 * H + 0.5 * M
hun_rad = 6 * M
diff = abs(ji_rad - hun_rad)
if diff == 0:
  answer = abs(ji - hun)
elif diff == 180:
  answer = ji + hun
else:
  if diff > 180:
      diff = abs(360 - diff)
  answer = math.sqrt((ji ** 2) + (hun ** 2) - 2 * ji * hun * math.cos(math.radians(diff)))
print(answer)

Buggy python submission (verdict: Runtime Error):
import math
tan, tyou, hour, minute = input()
tan_rad = 30 * hour
tyou_rad = 6 * minute
if tan_rad == tyon_rad:
  answer = abs(tyou - tan)
else:
  rad = abs(tan_rad - tyou_rad)
if rad:
  answer = math.sqrt((tan ** 2) + (tyou ** 2) - 2 * tan * tyou * math.cos(math.radius(rad)))
print(answer)

Fixed submission:
import math
ji, hun, H, M = input().split()
ji = int(ji)
hun = int(hun)
H = int(H)
M = int(M)
ji_rad = 30 * H + 0.5 * M
hun_rad = 6 * M
diff = abs(ji_rad - hun_rad)
if diff == 0:
  answer = abs(ji - hun)
elif diff == 180:
  answer = ji + hun
else:
  if diff > 180:
      diff = abs(360 - diff)
  answer = math.sqrt((ji ** 2) + (hun ** 2) - 2 * ji * hun * math.cos(math.radians(diff)))
print(answer)

Buggy python submission (verdict: Runtime Error):
import math
tan, tyou, hour, minute = input()
tan_rad = 30 * hour
tyou_rad = 6 * minute
if tan_rad == tyon_rad:
  answer = abs(tyou - tan)
else:
  rad = abs(tan_rad - tyou_rad)
if rad:
  answer = math.sqrt((tan ** 2) + (tyou ** 2) - 2 * tan * tyou * math.sin(math.radius(rad)))
print(answer)

Fixed submission:
import math
ji, hun, H, M = input().split()
ji = int(ji)
hun = int(hun)
H = int(H)
M = int(M)
ji_rad = 30 * H + 0.5 * M
hun_rad = 6 * M
diff = abs(ji_rad - hun_rad)
if diff == 0:
  answer = abs(ji - hun)
elif diff == 180:
  answer = ji + hun
else:
  if diff > 180:
      diff = abs(360 - diff)
  answer = math.sqrt((ji ** 2) + (hun ** 2) - 2 * ji * hun * math.cos(math.radians(diff)))
print(answer)