S = raw_input() M1 = int(S[0:2]) M2 = int(S[3:5])+5 if M2 >= 60: M2 = M2-60 M1 = M1+1 if M1 >= 24: M1 = M1-24 print "%02.f" % (M1)+":"+ "%02.f" % (M2)