Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- #include <stdlib.h>
- #include <time.h>
- int main()
- {
- time_t secondes;
- struct tm instant;
- time(&secondes);
- instant =* localtime(&secondes);
- printf("Il est actuellement : %d:%d:%d\n", instant.tm_hour, instant.tm_min, instant.tm_sec);
- int nbMinutes = (instant.tm_hour-15)*60 + instant.tm_min;
- printf("Il y a %d minutes que 15:00:00 est passe", nbMinutes);
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement