获得系统时间 #include<iostream> #include<ctime> using namespace std; int main() { time_t now_time; now_time = time(NULL); cout<<now_time; getchar(); return 0; }