반응형
https://www.acmicpc.net/problem/2530
# @Author YoungMinKim
# baekjoon
import datetime
h,m,s = map(int,input().split())
s2 = int(input())
now = str(datetime.timedelta(hours=h,minutes=m,seconds=s)+datetime.timedelta(seconds=s2))
h = now.split(':')[0]
m = now.split(':')[1]
s = now.split(':')[2]
if len(h)>2:
h = h.split(',')[1].split(' ')[1]
print(int(h),int(m),int(s))
반응형
'백준 문제풀이' 카테고리의 다른 글
baekjoon - python - 2557 (0) | 2020.08.25 |
---|---|
baekjoon - python - 2555 (0) | 2020.08.24 |
baekjoon - python - 2525 (0) | 2020.08.24 |
baekjoon - python - 2523 (0) | 2020.08.24 |
baekjoon - python - 2480 (0) | 2020.08.24 |
댓글