运行 ❯
获取您的
个人
网站
×
更改方向
更改主题,深色/浅色
转至“空间”
#include <iostream> #include <ctime> using namespace std; int main() { time_t now; struct tm * date; time(&now); date = localtime(&now); cout << "Local time: " << asctime(date); return 0; } // Note: This example displays the server's local time, which may differ from your local time.