masonxiong @ 2024-10-14 18:29:01
作为一道单调队列优化 DP 的几乎板子题,这题把我一个朴素 DP 放过去太合适吧。
建议加强数据,只需要制造
#include <bits/stdc++.h>
using namespace std;
const int N = 1e5, L = 1, R = N;
const int Aupper = 1000, Alower = -1000;
const char *fileName = "file.in";
int main() {
srand(time(NULL));
FILE *file = fopen(fileName, "w");
fprintf(file, "%d %d %d\n", N, L, R);
for (int i = N; i--; fprintf(file, "%d%c", rand() % (Aupper - Alower + 1) + Alower, " \n"[i == 0]));
return 0;
}
by why100 @ 2024-10-25 18:25:51
等我A了再改(狗头保命)