【C++】程序计时

    技术2022-07-10  126

    #include<iostream> #include<ctime> using namespace std; int main() { clock_t start, end; start = clock(); // task code end= clock(); double endtime = (double)(end - start) / CLOCKS_PER_SEC; cout << "Total time:" << endtime << "s" << endl; }
    Processed: 0.010, SQL: 9