27 lines
425 B
C
27 lines
425 B
C
#include <stdio.h>
|
|
#include <time.h>
|
|
#include <stdint.h>
|
|
|
|
int main(int argc, char *argv[])
|
|
{
|
|
putenv("TZ=");
|
|
tzset();
|
|
int64_t ss;
|
|
struct tm t;
|
|
//t.tm_isdst = -1;
|
|
t.tm_year = 2007;
|
|
t.tm_mon = 11;
|
|
t.tm_mday = 25;
|
|
t.tm_hour = 17;
|
|
t.tm_min = 33;
|
|
t.tm_sec = 52;
|
|
time_t time = mktime(&t);
|
|
t = *gmtime(&time);
|
|
printf("%d.%d.%d %d:%d:%d", t.tm_year, t.tm_mon, t.tm_mday, t.tm_hour, t.tm_min, t.tm_sec);
|
|
|
|
|
|
|
|
return 0;
|
|
}
|
|
|