对拍学习

(蒯的\(lyd\)的)

for (int i = 1; i <= 10000; i ++ )
{
    // 自行设定适当路径 
    system("C:\\random.exe");
    // Unix:system("./random");
    // Windows:ms; Unix:s 
    double st = clock();
    system("C:\\sol.exe");
    double ed = clock();
    system("C:\\bf.exe");
    if (system("fc C:\\data.out C:\\data.ans")) // Unix:diff -b
    {
    	puts("WA");
    	return 0;
    }
    else printf("AC, 测试点 #%d, 用时 %.0lfms\n", i, ed - st);
}

posted @ 2020-10-22 11:51  andysj  阅读(67)  评论(0编辑  收藏  举报