跳到正文

剪贴板

剪贴板 losv3esr

原文
剪贴板信息

剪贴板信息

收录
更新
C++
#include <bits/stdc++.h>
using namespace std;
string s = "start https://www.luogu.com.cn/problem/";
int x;
void solve(){
    int res = rand() % 3;
    if(res == 0){
        string p = s + "P" + to_string(rand() % 9000 + 1000);
        system(p.c_str());
    }
    if(res == 1){
        string p = s + "CF" + to_string(rand() % 2000) + (char)(rand() % 5 + 'A');
        system(p.c_str());
    }
    if(res == 2){
        string p = s + "AT_abc" + to_string(rand() % 300) + "_" + (char)(rand() % 5 + 'A');
        system(p.c_str());
    }
}
int main(){
	cout << "请输入随机跳转的数量";
    ios::sync_with_stdio(0);
    cin.tie(0) , cout.tie(0);
    srand(time(0));
    for(cin >> x; x--; solve());
    return 0;
}