dev/c/localtime/localtime.c

16 lines
252 B
C
Raw Normal View History

2011-12-05 19:15:15 +04:00
#include <stdio.h>
#include <time.h>
#include <inttypes.h>
int main(void)
{
time_t result;
result = time(NULL);
printf("%s%ju secs since the Epoch\n",
asctime(localtime(&result)),
(uintmax_t)result);
return(0);
}