john_he 发表于 2007-8-19 20:26:26

C标准库里有没有计时函数?

类似于GetTickCount的,精度毫秒级以上。

john_he 发表于 2007-8-19 20:34:18

找到了……


clock

Libraries

All versions of the C run-time libraries.

Calculates the wall-clock time used by the calling process.

clock_t clock( void );

Return Value
The elapsed wall-clock time since the start of the process (elapsed time in seconds times CLOCKS_PER_SEC). If the amount of elapsed time is unavailable, the function returns –1, cast as a clock_t.


各位请WS掉吧。
页: [1]
查看完整版本: C标准库里有没有计时函数?