//C语言
#include<stdio.h>
int main(){
int seconds;
scanf("%d",&seconds);
int days=seconds/(24*3600);
seconds%=24*3600;
int hours=seconds/3600;
seconds%=3600;
int minutes=seconds/60;
seconds%=60;
printf("%d:%d:%d:%d",days,hours,minutes,seconds);
return 0;
}