全部评论 1

  • 计算运行时间的代码是
    clock_t start , end;
    start = clock(); // 记录开始时间
    solve();//需要计算时间的代码
    end = clock();// 记录结束时间
    printf("%.2lf MS",double(end-start) / CLOCKS_PER_SEC * 1000 ); // 转换成小数模式

    2024-03-20 来自 广东

    0

热门讨论