版本比较
lg/CF 跳题器
正文
增加 14 行删除 14 行
12345667891029 行未改动4041424344444546474828 行未改动77787980818182838485868788899090919293943 行未改动98991001011021021031041041051061071081091101111121121131141151164 行未改动12112212312412512512612712812956 行未改动18618718818919019019119219319419519619719819819920020020120220320438 行未改动2432442452462472472482492502512 行未改动2542552562572582592582592602612622635 行未改动```cpp#include<bits/stdc++.h>#include<windows.h>#include<conio.h>
using namespace std; using namespace std;
int last_move_time = clock();void TopWindow() { HWND hWnd = GetConsoleWindow();29 行未改动void rand_problem() { system("cls"); while(1) { TopWindow(); setpos(0, 0); setpos(0, 0); if(pos != 1) { cout << "1.CF"; } else {28 行未改动 continue; } if(GetAsyncKeyState(VK_RETURN) & 0x8000) { last_move_time = clock() + 100; if(pos == 1) { if(pos == 1) { string s = "start https://codeforces.com/problemset/problem/"; s += char('0' + rand() % 3 + 1); s += char('0' + rand() % 10); s += char('0' + rand() % 10); s += char('0' + rand() % 10); s += "/"; s += char('A' + rand() % 5); system(s.c_str()); system("cls"); system("cls"); } else if(pos == 2) { string s = "start https://www.luogu.com.cn/problem/"; int kind = rand() % 3;3 行未改动 s += char('0' + rand() % 10); s += char('0' + rand() % 10); if(kind == 2) { s += char('A' + rand() % 5); } } system(s.c_str()); system("cls"); system("cls"); } else if(pos == 3) { return; } } if(GetAsyncKeyState(VK_DOWN) & 0x8000) { pos = min(pos + 1, 3); last_move_time = clock() + 100; last_move_time = clock() + 100; } if(GetAsyncKeyState(VK_UP) & 0x8000) { pos = max(pos - 1, 1); last_move_time = clock() + 100;4 行未改动 system("cls"); pos = 1; while(1) { TopWindow(); setpos(0, 0); setpos(0, 0); if(pos != 1) { cout << "1.CF"; } else {56 行未改动 } } if(GetAsyncKeyState(VK_DOWN) & 0x8000) { pos = min(pos + 1, 3); last_move_time = clock() + 100; last_move_time = clock() + 100; } if(GetAsyncKeyState(VK_UP) & 0x8000) { pos = max(pos - 1, 1); last_move_time = clock() + 100; } }}
int main() { HideCursor(); HideCursor(); TopWindow(); srand(time(0)); a : cout << "press the key tab to hide the cursur, and then, it's will not still run when you don't want to run it, if you need it, you can press key tab again.\n";38 行未改动 continue; } if(GetAsyncKeyState(VK_RETURN) & 0x8000) { last_move_time = clock() + 300; if(pos == 1) { if(pos == 1) { rand_problem(); } else if(pos == 2) { choose_problem();2 行未改动 return 0; } } if(GetAsyncKeyState(VK_DOWN) & 0x8000) { pos = min(pos + 1, 3); last_move_time = clock() + 100; pos = min(pos + 1, 3); last_move_time = clock() + 100; } if(GetAsyncKeyState(VK_UP) & 0x8000) { pos = max(pos - 1, 1); last_move_time = clock() + 100;5 行未改动