TO CONVERT HOURS INTO SECONDS

#include<stdio.h>
#include<conio.h>
#include<math.h>
void main()
{
int a,b,c,s;
clrscr();
printf("enter the time in hour minutes and seconds");
scanf("%d %d %d",&a,&b,&c);
s=(a*3600)+(b*60)+c;
printf("\n the time in seconds is %d",s);
getch();
}

No comments:

Related Posts with Thumbnails