To tylko jedna z 2 stron tej notatki. Zaloguj się aby zobaczyć ten dokument.
Zobacz
całą notatkę
The function time time_t time(time_t *timer); time gives the current time, in seconds, elapsed since 00:00:00 GMT, January 1, 1970 It stores that value in the location *timer, provided that timer is not a null pointer #include #include int main() { time_t t; struct tm *newTime; t = time(NULL); printf("The number of seconds since January 1," " 1970 is %ld\n",t); newTime = localtime(&t); printf("The current time is: %s\n",asctime(newTime)); return 0; } The number of seconds since January 1, 1970 is 1262600228 The current time is: Mon Jan 4 11:17:08 2010
... zobacz całą notatkę
Komentarze użytkowników (0)