#pragma once
#include <ctime>
#include "lib.h"
class testtime
{
public:
int start_s = 0,stop_s = 0;
void starttesttime(){
start_s = clock();
stop_s = 0;
},
stoptesttime(std::string t){
stop_s = clock();
std::cout << t << " time: " << (stop_s - start_s) / double(CLOCKS_PER_SEC) << std::endl;
start_s = 0;
};
};
Run Code Online (Sandbox Code Playgroud)
我得到了严重性代码描述项目文件行抑制状态
Error (active) E0169 expected a declaration test c:\Users\AWW\Desktop\test\test\testtime.h 12 .
Severity Code Description Project File Line Suppression State
Error C2059 syntax error: ',' test c:\users\aww\desktop\test\test\testtime.h 12
Severity Code Description …
Run Code Online (Sandbox Code Playgroud) c++ ×1