QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#673922 | #5438. Half Mixed | xcyyyyy | WA | 0ms | 3872kb | C++20 | 398b | 2024-10-25 11:48:14 | 2024-10-25 11:48:14 |
Judging History
answer
#include<bits/stdc++.h>
using namespace std;
#define N 5005
#define M 10005
#define p 998244353
#define ll long long
void work(){
int n,m;
scanf("%d%d",&n,&m);
if((n&1)&&(m&1))return puts("No"),void();
puts("Yes");
for(int i=1;i<=n;i++,puts(""))for(int j=1;j<=m;j++)
printf("%d ",(i+j)&1);
}
int main(){
int t;scanf("%d",&t);while(t--)
work();
}
Details
Tip: Click on the bar to expand more detailed information
Test #1:
score: 0
Wrong Answer
time: 0ms
memory: 3872kb
input:
2 2 3 1 1
output:
Yes 0 1 0 1 0 1 No
result:
wrong answer 12 Mixed Submatrices Found, but 9 Expected (test case 1)