C++ 测试程序运行时间

2019-03-09  本文已影响0人  Young1217
#include <ctime>


clock_t startTime,endTime;

startTime = clock();
auto vars = mpc.Solve(state, coeffs);
endTime = clock();
cout << "The run time is: " << (double)(endTime - startTime) / CLOCKS_PER_SEC  << "s" << endl;
    
上一篇 下一篇

猜你喜欢

热点阅读