import datetime



n = int(input().rstrip())





#??????

int_hour = n // 3600

int_minute = (n % 3600) // 60

int_second = n- int_hour*3600 - int_minute * 60



# ??????????????????

print(int_hour,int_minute, int_second, sep=":" )

n = int(input().rstrip())





#??????

int_hour = n // 3600

int_minute = (n % 3600) // 60

int_second = n- int_hour*3600 - int_minute * 60



# ??????????????????

print(int_hour,int_minute, int_second, sep=":" )

import datetime

n = int(input().rstrip())
# ??????
int_hour = n // 3600
int_minute = (n % 3600) // 60
int_second = n - int_hour * 3600 - int_minute * 60
# ??????????????????
print(int_hour, int_minute, int_second, sep=":")

n = int(input().rstrip())
# ??????
int_hour = n // 3600
int_minute = (n % 3600) // 60
int_second = n - int_hour * 3600 - int_minute * 60
# ??????????????????
print(int_hour, int_minute, int_second, sep=":")

-import datetime -