- 博客(1)
- 资源 (1)
- 收藏
- 关注
转载 VC++获得当前系统时间的几种方案
strftime( tmp, sizeof(tmp), "%Y/%m/%d %X %A 本年第%j天 %z",printf( "%4d/%02d/%02d %02d:%02d:%02d.%03d 星期%1d\n"//方案二 优点:能精确到毫秒级;缺点:使用了windows API。//方案— 优点:仅使用C标准库;缺点:只能精确到秒级。另一:_strdate(tempstr);//方案三,优点:利用系统函数。可以改变电脑的时间设定。
2025-05-29 14:52:09
40
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人