C++获取毫秒级别的当前时间

#include <windows.h>
#include <stdio.h>
#include <time.h>


int main ()
{
SYSTEMTIME lpsystime;
GetLocalTime(&lpsystime);
printf("%u:%u:%u:%u:%u:%u:%u:%u\n",lpsystime.wYear,lpsystime.wMonth,lpsystime.wDayOfWeek,lpsystime.wDay,lpsystime.wHour,lpsystime.wMinute,lpsystime.wSecond,lpsystime.wMilliseconds);
getchar();
return 0;
} 

 

你可能感兴趣的:(C++获取毫秒级别的当前时间)