h,m = map(int,input().split(":")) m += 5 if m >= 60: m -= 60 h += 1 if h >= 24: h -= 24 print(str(h).rjust(2,"0") + ":" + str(m).rjust(2,"0"))