QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#459830 | #8474. Matrices and Sums | abbcc_1 | WA | 1ms | 3600kb | C++20 | 468b | 2024-06-30 14:19:23 | 2024-06-30 14:19:24 |
Judging History
answer
#include <bits/stdc++.h>
using namespace std;
using i64 = long long;
int main() {
ios::sync_with_stdio(false);
cin.tie(nullptr);
int n;
cin >> n;
if (n & 1) {
cout << "NO\n";
} else {
cout << "YES\n";
for (int i = 1; i <= n; i++) {
for (int j = 1; j <= n; j++) {
cout << (2 * j <= n) - (i + j > n + 1) << " \n"[j == n];
}
}
}
return 0;
}
Details
Tip: Click on the bar to expand more detailed information
Test #1:
score: 0
Wrong Answer
time: 1ms
memory: 3600kb
input:
2
output:
YES 1 0 1 -1
result:
wrong answer Line "YES" doesn't correspond to pattern "No|Yes"