在同一个文件夹写如下代码
- 数据生成器
//以a+b为例
#include <bits/stdc++.h>
using namespace std;
int main() {
ios::sync_with_stdio(false);
cin.tie(nullptr);
cout.tie(nullptr);
srand(time(0));
int a=rand()%20000+1;
int b=rand()%20000+1;
cout<<a<<" "<<b<<"\n";
}- 暴力(对拍时用的正解,一定要写对)
- 待对拍代码 以上三个代码写完后都要运行一下
- 对拍.bai
:loop
gen > 1.txt
std < 1.txt > 2.txt
bl < 1.txt > 3.txt
fc 2.txt 3.txt
if errorlevel 1 pause
goto loop