strtime.cpp
来自「数据结构常用算法合集」· C++ 代码 · 共 15 行
CPP
15 行
//strtime.cpp
#include <time.h>
#include <iostream.h>
#include <conio.h>
void main(void)
{
char datebuf[9];
char timebuf[9];
_strdate(datebuf);
_strtime(timebuf);
cout<<"目前日期:"<<datebuf<<endl
<<"现在时刻:"<<timebuf<<endl;
getch();
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?