프로젝트/Baekjoon
BAEKJOON PYTHON 2884 알람 시계
Refrin
2021. 8. 20. 00:16
반응형
Prob
Approach
기본 문법
예외 처리 깔끔하게!
Code
h, m = input().split()
h = int(h)
m = int(m)
if (m - 45) >= 0 :
print(h, m - 45)
else :
if(h > 0) :
print(h-1, (m + 60) - 45)
else :
print(23, (m + 60) - 45)
출처
반응형