1
我在C++ http://aliarth.lt/date.cpp上創建date()函數,我得到localtome_to_time()
轉換的一個問題。有誰知道如何local_time變量:本地時間轉換爲time_t(C++)
int time_integer = 12345;
time_t time = (time_t)time_integer;
tm *local_time = localtime(&time);
local_time->tm_year = 100;
local_time->tm_mon = 10;
local_time->tm_mday = 1;
轉換爲time_t
?