您的位置:首页 > 其它

vc获取程序运行时间

2011-03-02 10:50 302 查看
#include<iostream>

#include<ctime>

using namespace std;

int main()

{

time_t begin,end;

begin=clock();

//这里加上你的代码

end=clock();

cout<<"runtime: "<<double(end-begin)/CLOCKS_PER_SEC<<endl;

}

 
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: