📅  最后修改于: 2022-03-11 14:44:47.605000             🧑  作者: Mango
int main()
{
time_t start, end;
time(&start); // start time
// {your code goes here}
time(&end); // end time
double time_taken = double(end - start); // calulate diffrence
std::cout << " duration: " << time_taken << " s \n";
}