[Solved] conversion from milliseconds to hours in C [closed]


Just assuming there are two variables A & B.

long long B; // B is the required milliseconds

printf("Enter the required ms: ");
scanf("%lli", &B);

double A = (double) B / 3600000; // to hours

printf("%lf\n", A);

Disclaimer: Your program has no such declaration which is written in your question. But for sake of simplicity, I just showed the easy method conversion of milliseconds into hours.

1

solved conversion from milliseconds to hours in C [closed]