C++:使用C++和Windows API函数绘制当前时间 #include <Windows.h> int main() { HDC hdc = GetDC(NULL); // 获取屏幕上下文句柄 SYSTEMTIME st