Ticcount
코드
#include <stdio.h>
#include <windows.h>
int main(int argc, char* argv[]){
DWORD startTickCount = GetTickCount();
DWORD currentTickCount;
for ( ; ; ){
currentTickCount = GetTickCount();
printf("현재 틱 카운트 : %lu\n", currentTickCount);
if (currentTickCount - startTickCount >= 1000){
printf("1 초 지나서 프로그램 종료\n");
break;
}
}
return 0;
}
출처
https://kkikkodev.tistory.com/49
댓글남기기