QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#603224#9415. Matrixucup-team3474WA 0ms3700kbC++201004b2024-10-01 15:23:592024-10-01 15:24:00

Judging History

你现在查看的是最新测评结果

  • [2024-10-01 15:24:00]
  • 评测
  • 测评结果:WA
  • 用时:0ms
  • 内存:3700kb
  • [2024-10-01 15:23:59]
  • 提交

answer

#include<bits/stdc++.h>
using namespace std;
const int N=1919810,mod=1e9+7;
typedef long long ll;
typedef pair<ll,ll> PII;
ll n,m,k;
ll a[N],b[N];
char s[N];

ll dp[N];
int c[100][100];

bool check(){

    int ans=0;
    for(int i=1;i<=n;i++){
        for(int j=1;j<=n;j++){
            for(int k=i+1;k<=n;k++){
                for(int u=j+1;u<=n;u++){
                    set<int> se;
                    se.insert(c[i][j]);
                    se.insert(c[k][j]);
                    se.insert(c[i][u]);
                    se.insert(c[k][u]);
                    if(se.size()==4) ans++;
                }
            }
        }
    }
    return ans==1;
}

void __(){
    scanf("%d",&n);
    if(n>=4) puts("No");
    else{
        puts("Yes");
        if(n==2){
            puts("1 2\n3 4");
        }else{
            puts("3 2 6\n4 3 3\n3 1 5\n");
        }
    }
}


int main(){
    int _=1;
    // cin>>_;
    while(_--){
        __();
    }
}

Details

Tip: Click on the bar to expand more detailed information

Test #1:

score: 100
Accepted
time: 0ms
memory: 3644kb

input:

2

output:

Yes
1 2
3 4

result:

ok Correct. (1 test case)

Test #2:

score: 0
Accepted
time: 0ms
memory: 3700kb

input:

3

output:

Yes
3 2 6
4 3 3
3 1 5


result:

ok Correct. (1 test case)

Test #3:

score: -100
Wrong Answer
time: 0ms
memory: 3644kb

input:

4

output:

No

result:

wrong answer Jury has answer while participant hasn't. (test case 1)