Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
First solution in Clear category for Sun Angle by J.schubert262
def sun_angle(time):
t = int(time[:2]) * 15 + int(time[3:]) / 4 - 90
return t if 0 <= t <= 180 else "I don't see the sun!"
print("Example:")
print(sun_angle("07:00"))
assert sun_angle("07:00") == 15
assert sun_angle("12:15") == 93.75
print("The mission is done! Click 'Check Solution' to earn rewards!")
April 25, 2023
Comments: