啊啊啊啊啊啊,我要疯阿巴阿巴阿巴
查看原帖
啊啊啊啊啊啊,我要疯阿巴阿巴阿巴
1080331
douyachong楼主2023/12/31 12:37
#include<bits/stdc++.h>
using namespace std;
int main(){
    long long int a[10],b[10],m=0,k,x,y=0;
    for(int i=1;i<=7;i++){
        cin>>a[i]>>b[i];
    }
    for(int j=1;j<=7;j++){
        if(a[j]+b[j]>8)
        m=1;
        if(a[j]+b[j]>x) {
            x=a[j]+b[j];
            y=j;
        }
    }
    if(m=0) cout<<0;
    else cout<<y;
    return 0;
}

#12WA,我的强迫症要犯了!!!

2023/12/31 12:37
加载中...