h,m=map(int,input().split(":")) m+=5 h=(h+m//60)%24 m%=60 print(f"{h:02}:{m:02}")