参考代码:
n=int(input())
a=86400
s=n//1000%a
h=s//3600
s=s-h*3600
m=s//60
s=s-m*60
if(h<10 and m<10 and s<10 ):
print("0{}:0{}:0{}".format(h,m,s))
elif(h<10 and m<10 ):
print("0{}:0{}:{}".format(h,m,s))
elif(h<10 and s<10 ):
print("0{}:{}:0{}".format(h,m,s))
elif(m<10 and s<10 ):
print("{}:0{}:0{}".format(h,m,s))
elif(h<10 ):
print("0{}:{}:{}".format(h,m,s))
elif(m<10 ):
print("{}:0{}:{}".format(h,m,s))
elif(s<10 ):
print("{}:{}:0{}".format(h,m,s))
0.0分
0 人评分