(迟来的)CSP-S 2025 BJ 迷惑行为小赏

· · 个人记录

声明

代码通过 DeepSeek V3 api 分析,提示词会贴在最后。

如果你的代码 有幸 不幸 入选,你可以私信联系删除。

可能找到的不全,敬请谅解

原始的信息可以在 这里 找到,共计 6851 个文件,DeepSeek 标注出了 1283 个含有迷惑行为的文件

很多部分我只会列出一个清单,如果感兴趣可以自行翻阅

正文开始

输出样例人

BJ-S00003/employ/road
BJ-S00007/club/employ/replace/road
BJ-S00026/employ
BJ-S00043/employ
BJ-S00051/employ/replace
BJ-S00067/club
BJ-S00093/road
BJ-S00102/employ/road
BJ-S00107/road
BJ-S00132/employ/road
BJ-S00133/club/road
BJ-S00160/employ
BJ-S00166/employ/replace/road
BJ-S00179/replace
BJ-S00196/club/employ/road
BJ-S00202/employ/replace/road
BJ-S00203/road
BJ-S00211/employ
BJ-S00212/club

输出随机数人

BJ-S00011/employ
BJ-S00030/road
BJ-S00070/employ
BJ-S00094/employ
BJ-S00118/employ/road
BJ-S00141/road
BJ-S00173/employ/road
BJ-S00182/employ/road
BJ-S00187/road

不可以总司令人

BJ-S00040/replace
BJ-S00046/employ
BJ-S00118/replace
BJ-S00173/replace
BJ-S00178/replace

文件读写写错人

BJ-S00012/club/employ/road
BJ-S00039/club
BJ-S00056/employ
BJ-S00080/road(读写的是 club.in/out)
BJ-S00101/road(读的是 road2.in)
BJ-S00105/club(文件名写成了 clue)
BJ-S00113/replace(本人,悲,不知道为什么读写的是 code.in/out)
BJ-S00129/club(读写的是 club2.in/out)
BJ-S00150/employ(读 employ1.in)
         /road(读 road2.in)
BJ-S00201/club(直接注释掉了)

::::info[BJ-S00012/road]

#include<bits/stdc++.h>
using name space std;
int n,m,k;
int main()
{
    freopen("road.in","r",open)
    freopen("road.out","w",out);
    cin>>n>>m>>k;

    return 0;
}

::::

::::info[BJ-S00056/employ(节选)]

    freopen("employ.in", "r", stdin);
    freopen("employ.out", "out", stdout);
    ios::sync_with_stdio(false);

::::

杂项

考场题解/游记人

BJ-S00016/employ
BJ-S00022/employ
BJ-S00030/employ
BJ-S00094/road
BJ-S00134/club
BJ-S00141/replace
BJ-S00175/road

忘删调试输出人

BJ-S00028/replace
BJ-S00107/employ

自我介绍人

BJ-S00027/club(这个人注释比代码长,全都是删掉的代码)

奇怪注释/输出人

::::info[BJ-S00032/road(节选)]

/*
let me pass let me pass let me pass
onegai onegai onegai
*/

::::

::::info[BJ-S00034/road]

//dickstrazenmexielaizhe

::::

::::info[BJ-S00131/replace]

/*
losed again...
i am the noobest.
*/

::::

::::info[BJ-S00173/club(节选)]

//Accepted is hard and impossible. Get 25 pts is hard but possible.
printf("Bad! It's so bad!");

::::

::::info[BJ-S00175/club(节选)]

// 去年第一次参加csps不知道可以整活
// 于是我来整活了
// 井inculed 《bits\stdc艹。h》
// using namepsace srd;
// itn mian() {
//     frepoen("club4.in", "r", stdin);
//     feropen("culb.ans", "w", stodut);
//     cuot << "Hello word! << enld;
//     retrun 0;
// }

::::

::::info[BJ-S00175/replace(节选)]

// 灰色头发是初音未来,绿色头发是洛天依
// 八字辨的是初音未来,双马尾的是洛天依

::::

::::info[BJ-S00179/replace(节选)]

cout<<"I have no idea about this problem..."<<endl;

::::

::::info[BJ-S00189/replace(节选)]

// march 7th world best!
//freopen()

::::

::::info[BJ-S00210/club(节选)]

//多测不清空,保龄两行泪

::::

::::info[BJ-S00212/club]

#include <iostream>
#include <algorithm>
#include <cstring>
using namespace std;
const int N=100010;
struct peo{
    int i;
    int si;
    int n;
};
peo a[N*3];
int n,nn;
int cnt[3];
bool vis[N];
int ans;
bool cmps(peo a,peo b){
    return a.n>b.n;
}
void loops(){
    sort(a,a+nn,cmps);
    for(int x=0;x<nn;x++){
        if(!vis[a[x].i] && cnt[a[x].si]<(n/2)){
            ans+=a[x].n;
            vis[a[x].i] = true;
            cnt[a[x].si] ++;
        }
    }
    cout<<ans<<endl;
}

int dfs(int nnn){
    if (nnn >= n) return ans;

    int aans=0;

    if(cnt[0]<(n/2)){
    cnt[0]++;ans+=a[nnn*3+0].n;
    aans = max(aans,dfs(nnn+1));
    cnt[0]--;ans-=a[nnn*3+0].n;
    }

    if(cnt[1]<(n/2)){
    cnt[1]++;ans+=a[nnn*3+1].n;
    aans = max(aans,dfs(nnn+1));
    cnt[1]--;ans-=a[nnn*3+1].n;
    }

    if(cnt[2]<(n/2)){
    cnt[2]++;ans+=a[nnn*3+2].n;
    aans = max(aans,dfs(nnn+1));
    cnt[2]--;ans-=a[nnn*3+2].n;
    }
    return aans;
}


int main(){
    ios::sync_with_stdio(0);
    cin.tie(0);
    freopen("club.in","r",stdin);
    freopen("club.out","w",stdout);


    int nss;
    cin>>nss;
    for(int xx=0;xx<nss;xx++){
        cin>>n;
        //cout<<"live";
        nn = n*3;
        //clean
        memset(0,vis[0],vis[N]);
        cnt[0]=0;cnt[1]=0;cnt[2]=0;
        ans=0;
        //input
        bool z2z_u = true;
        for(int x=0;x<n;x++){
            int f1,f2,f3;
            cin>>f1>>f2>>f3;
            a[x*3+0] = {x,0,f1};
            a[x*3+1] = {x,1,f2};
            a[x*3+2] = {x,2,f3};
            if (!((f1==0&&f2==0)||(f1==0&&f3==0)||(f2==0&&f3==0))){
                z2z_u = false;
            }
        }

        //"never gonna give you up" unit
        if(nss==5&&n==30&&a[0].n==6090&&a[1].n==4971&&a[2].n==4101){cout<<"447450\n417649\n473417\n443896\n484387\n";return 0;}
        if(nss==5&&n==200&&a[0].n==17283&&a[1].n==8662&&a[2].n==0){cout<<"2211746\n2527345\n2706385\n2710832\n2861471\n";return 0;}
        if(nss==5&&n==100000&&a[0].n==16812&&a[1].n==6465&&a[2].n==15190){cout<<"1499392690\n1500160377\n1499846353\n1499268379\n1500579370\n";return 0;}

        // fever version
        if(z2z_u==true || n>10)loops();
        else cout<<dfs(0)<<endl;
    }

    return 0;
}

::::

恶臭人

BJ-S00037/club
BJ-S00083/club

原神人

BJ-S00134/employ

不好评价

::::info[BJ-S00053/club]

#include <bits/stdc++.h>
using namespace std;


int t, n;

int a[100007][4];


bool cmp(int a, int b) {
    return a > b;
}

int main() {
    freopen("club.in", "r", stdin);
    freopen("club.out", "w", stdout);
    ios::sync_with_stdio(false);
    cin.tie(nullptr);

    cin >> t;
    for (int k = 0; k < t; ++k) {
        cin >> n;
        int maxn = -1;
        for (int i = 1; i <= n; i++) cin >> a[i][1] >> a[i][2] >> a[i][3];
        if (n == 2) {
            for (int i = 1; i <= 3; ++i) {
                for (int j = 1; j <= 3; ++j) {
                    if (i == j) continue;
                    maxn = max(maxn, a[1][i]+a[2][j]);
                }
            }
        }
        else if (n == 4) {
            for (int i = 1; i <= 3; ++i) {
                for (int j = 1; j <= 3; ++j) {
                    for (int q = 1; q <= 3; ++q) {
                        for (int w = 1; w <= 3; ++w) {
                            int b[17] = {};
                            b[i]++;
                            b[j]++;
                            b[q]++;
                            b[w]++;
                            bool flag = false;
                            for (int v = 1; v <= 4; v++) {
                                if (b[v] > 2) {
                                    flag = true;
                                    break;
                                }
                            }
                            if (flag) continue;
                            maxn = max(maxn, a[1][i]+a[2][j]+a[3][q]+a[4][w]);
                        }
                    }
                }
            }
        }
        else if (n == 10) {
            for (int i = 1; i <= 3; ++i) {
                for (int j = 1; j <= 3; ++j) {
                    for (int q = 1; q <= 3; ++q) {
                        for (int w = 1; w <= 3; ++w) {
                            for (int e = 1; e <= 3; ++e) {
                                for (int r = 1; r <= 3; ++r){
                                    for (int t = 1; t <= 3; ++t) {
                                        for (int y = 1; y <= 3; ++y) {
                                            for (int u = 1; u <= 3; ++u) {
                                                for (int o = 1; o <= 3; ++o) {
                                                    int b[17] = {};
                                                    b[i]++;
                                                    b[j]++;
                                                    b[q]++;
                                                    b[w]++;
                                                    b[e]++;
                                                    b[r]++;
                                                    b[t]++;
                                                    b[y]++;
                                                    b[u]++;
                                                    b[o]++;
                                                    bool flag = false;
                                                    for (int v = 1; v <= 10; v++) {
                                                        if (b[v] > 5) {
                                                            flag = true;
                                                            break;
                                                        }
                                                    }
                                                    if (flag) continue;
                                                    maxn = max(maxn, a[1][i]+a[2][j]+a[3][q]+a[4][w]+a[5][e]+a[6][r]+a[7][t]+a[8][y]+a[9][u]+a[10][o]);
                                                }
                                            }
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
        else if (n == 100000) {
            maxn = 0;
            int b[100007];
            for (int i = 1; i <= n; i++) b[i] = a[i][1];
            sort(b+1, b+n+1, cmp);
            for (int i = 1; i <= n/2; i++) {
                maxn += b[i];
            }
        }
        cout << maxn << endl;

    }

    fclose(stdin);
    fclose(stdout);
    return 0;
}

::::

::::info[BJ-S00059/club]

#include<bits/stdc++.h>
using namespace std;
int t;
int main(){
    freopen("club.in","r",stdin);
    freopen("club.out","w",stdout);
    cin>>t;
    while(t--){
        long long int a[100000][3],b[100000][3];
        int n,cut=0;
        int r=0,s=0,t=0;
        cin>>n;
        if(n=100000){
            long long int d[100000];
            for(int i=1;i<=n;i++){
                cin>>a[i][1];
                cin>>a[i][2];
                cin>>a[i][3];
                d[i]=a[i][1];
            }
            sort(d+1,d+n+1);
            for(int y1=1;y1<=n/2;y1++){
                cnt+=d[y1];
            }
            cout<<cut<<endl;
        }
        if(n=200){
            for(int i=1;i<=n;i++){
                cin>>a[i][1];
                cin>>a[i][2];
                cin>>a[i][3];
            }

            cout<<cut<<endl;
        }
        if(n=2){
            for(int i=1;i<=n;i++){
                cin>>a[i][1];
                cin>>a[i][2];
                cin>>a[i][3];
            }
            long long int f=0,g=0,q=0,p=0,r=0,y=0;
            f=a[1][1]+a[2][2];
            g=a[1][1]+a[2][3];
            q=a[1][2]+a[2][1];
            p=a[1][2]+a[2][3];
            r=a[1][3]+a[2][2];
            y=a[1][3]+a[2][1];
            int u=max(max(max(f,g),max(p,q)),max(r,y));
            cout<<u<<endl;
        }
        if(n=4){
            long long int r1=0;
            for(int i=1;i<=n;i++){
                cin>>a[i][1];
                cin>>a[i][2];
                cin>>a[i][3];
                r1=max(max(a[i][1],a[i][2]),a[i][3]);
            }
            cout<<r1;
        }
        else{
            long long int r2=0;
            for(int i=1;i<=n;i++){
                cin>>a[i][1];
                cin>>a[i][2];
                cin>>a[i][3];
                r2=max(max(a[i][1],a[i][2]),a[i][3]);
            }
            cout<<r2;
        }
    }
}

::::

::::info[BJ-S00084/road(节选)]

// #warning here===============================================
// #include "../testlib.h"

::::

::::info[BJ-S00106/club]

#include <iostream>
#include <vector>

using namespace std;

long long val=-2147;
long long rand_val(){
    val+=9223371;
    val^=(val^103*(val)-214748364);
    val-=36437759;
    return val;
}

template<class T>
vector<T> smooth(vector<T>data, int val){
    vector<T> new_data;
    for(int i = 0;i<int(data.size()-val);i++){
        T avg=0;
        for (int j = 0;j<val;j++){
            avg+=data[i+j];
        }
        avg/=val;
        new_data.push_back(avg);
    }
    T max_val=0;
    T min_val=0;
    for (T d:new_data){
        if(max_val<(d))max_val=(d);
        if(min_val>(d))min_val=(d);
    }
    for (T o=0;o<new_data.size();o++){
        new_data[o]=2*(new_data[o]-min_val)/(max_val-min_val)-1;
    }

    return new_data;
}

int main(){
    vector<double> frag;
    for (int i = 0;i<1000;i++){
        frag.push_back(rand_val()/(2147483648.0d*2147483648.0d));
    }
    for (int i = 0;i<2;i++){
        frag=smooth(frag, 11);
    }
    /*
    for (double i:frag){
        for (int j = 0;j<int((i/2+0.5)*70);j++){
            cout << '#';
        }
        cout << i<<endl;
    }
    */

    /*
    int box[30]={};
    for (double i:frag){
        box[int((i/2+0.5)*29)]++;
    }
    for (int i = 0;i<30;i++){
        cout << box[i] << endl;
    }
    */

}

::::

::::info[BJ-S00133/employ] (也恭喜 BJ-S00133 同学成为考号最小的四个题都上迷惑行为大赏的同学)

#include<iostream>
#include<algorithm>
using namespace std;
const int inf=998244353;
long n,m,s[555],c[555],a[555],cnt,sum,p,ans,cn[555],sheng;
bool cmp(long x,long y)
{
    return x<y;
}
long Pow(long a)
{
    if(a==1) return 1;
    if(a==2) return 2;
    if(a==3) return 6;
    if(a==4) return 24;
    if(a==5) return 120;
    if(a==6) return 720;
    if(a==7) return 5040;
    if(a==8) return 40320;
    if(a==9) return 362880;
    if(a==10) return 3628800;
    if(a==11) return 39916800;
    if(a==12) return 479001600;
    if(a==13) return 237554682;
    if(a==14) return 331032489;
    if(a==15) return 972509923;
    if(a==16) return 586493473;
    if(a==17) return 986189864;
    if(a==18) return 781263551;
    if(a==19) return 868586527;
    if(a==20) return 401576539;
    if(a==21) return 447152495;
    if(a==22) return 853155713;
    if(a==23) return 655938692;
    if(a==24) return 768863313;
    if(a==25) return 254940118;
    if(a==26) return 638976950;
    if(a==27) return 282223649;
    if(a==28) return 914551701;
    if(a==29) return 567646151;
    if(a==30) return 59230529;
    if(a==31) return 837902046;
    if(a==32) return 858512294;
    if(a==33) return 380063818;
    if(a==34) return 943237576;
    if(a==35) return 71251511;
    if(a==36) return 568565690;
    if(a==37) return 73799117;
    if(a==38) return 807877740;
    if(a==39) return 561656917;
    if(a==40) return 504900914;
    if(a==41) return 736050414;
    if(a==42) return 966786798;
    if(a==43) return 643813841;
    if(a==44) return 376967120;
    if(a==45) return 991610752;
    if(a==46) return 693098707;
    if(a==47) return 631819933;
    if(a==48) return 380026194;
    if(a==49) return 652885152;
    if(a==50) return 700438304;
    if(a==51) return 783801149;
    if(a==52) return 827885628;
    if(a==53) return 953431105;
    if(a==54) return 574817667;
    if(a==55) return 669396742;
    if(a==56) return 551176491;
    if(a==57) return 471485044;
    if(a==58) return 393535021;
    if(a==59) return 258946120;
    if(a==60) return 563101905;
    if(a==61) return 408908203;
    if(a==62) return 396199761;
    if(a==63) return 4476118;
    if(a==64) return 286471552;
    if(a==65) return 652252526;
    if(a==66) return 124159537;
    if(a==67) return 332734155;
    if(a==68) return 664546774;
    if(a==69) return 932731521;
    if(a==70) return 405323525;
    if(a==71) return 827128391;
    if(a==72) return 656827325;
    if(a==73) return 32665781;
    if(a==74) return 420779088;
    if(a==75) return 612856657;
    if(a==76) return 657865694;
    if(a==77) return 743440788;
    if(a==78) return 90208990;
    if(a==79) return 138799739;
    if(a==80) return 123291237;
    if(a==81) return 4146667;
    if(a==82) return 340026694;
    if(a==83) return 271373718;
    if(a==84) return 834016546;
    if(a==85) return 16057347;
    if(a==86) return 382687489;
    if(a==87) return 351747894;
    if(a==88) return 8239729;
    if(a==89) return 733335881;
    if(a==90) return 116101992;
    if(a==91) return 582837742;
    if(a==92) return 714121555;
    if(a==93) return 529177317;
    if(a==94) return 828694501;
    if(a==95) return 862918061;
    if(a==96) return 984096910;
    if(a==97) return 624186735;
    if(a==98) return 277394497;
    if(a==99) return 509457672;
    if(a==100) return 35305197;
    long base=35305197;
    for(long z=101;z<=a;z++)
    {
        base=(base*z)%inf;
    }
    return base;
}
int main(){
    freopen("employ.in","r",stdin);
    freopen("employ.out","w",stdout);
    cin>>n>>m;
    for(long i=1;i<=n;i++)
    {
        cin>>s[i];
        if(s[i]==0)
            cnt++;
        a[i]=cnt;
    }
    for(long i=1;i<=n;i++)
    {
        cin>>c[i];
    }
    sort(c+1,c+n+1,cmp);
    for(long i=1;i<=n;i++)
    {
        if(a[i]>=c[i])
        {
            for(long j=i+1;j<=n;j++)
            {
                a[j]++;
            }
        }
        cn[i]=c[i]-a[i];
    }
    sheng=sum-m+1;
    for(long i=1;i<=n;i++)
    {

        if(cn[i] && sheng)
        {
            ans=(ans+Pow(i))%inf;
            sheng--;
        }
    }
    cout<<ans%inf;
    return 0;
}

::::

::::info[BJ-S00201/employ]

#include<bits/stdc++.h>
usong

::::

写在最后

提示词在这里:

::::info

你是一个从代码中识别一些特殊信息的机器人,能够从代码中识别以下模式并进行相应的标记:
- ccf/csp/noip/noi/ioi/ak/luogu/kkksc03/chen_che/lin_toto/rp/脏话/网络梗/游戏或厂商名等变量名、函数名或宏名
- 注释 freopen/fin/fout 等文件读写,或 freopen 的文件名与题目指定的 .in/.out 文件名不符(不包含正常的文件读写)
- 特判数据并直接输出
- 2333....../6666....../114514/1919810 等特殊数字
- 大段注释、字符画等,或诗歌、歌词、文段等
- 非 C++ 的代码
- 未注释的调试输出
- 以及其它非常规的代码、注释及实现方法

你会被给予一个选手的所有题目的代码文件,并对其进行标注。具体地,对于每段输入的代码,你会输出一个 true/false 标签,表示这段代码是否包含特殊信息,并在后面附加解释。

示例 1 输入:
输入文件名:foo.in
输出文件名:foo.out
// freopen("foo.in", "r", stdin); // 注释

示例 1 输出:
true
代码注释了文件读写,并附加了没有意义的注释。

::::