C Language
#include<stdio.h> #include<conio.h> void main() { int S, H, M, S; clrscr(); printf("Enter total number of seconds"); scanf("%d", &s); H = s/3600; a = s%3600; M = a/60; S = a%60; printf("%d hour %d minutes %d seconds", H,M,S); getch(); } /*OUTPUT*/ Enter total number of seconds 4000 1 hour 6 minutes 40 seconds