#include #include #include #include #define TRUE 0 #define FALSE -1 void main(void){ time_t ltime; char time_c[128], week[4], month[4], day[3], hour[3], minute[3]; char second[3], year[5]; int i, len; printf("** TESTTIM : 現在の時刻と 10 分後の時刻 **\n"); getchar(); time(<ime); printf("(1) 現在の時刻 time = %s\n", ctime(<ime)); printf("+ 10 分 = 60.0 秒 \n"); ltime = ltime + 180; printf("(2)10 分後の時刻 time = %s\n", ctime(<ime)); getchar(); memset(time_c, 0, sizeof(time_c)); len = sprintf(time_c, "%s", ctime(<ime)); for(i = 0; i