QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#343424 | #6189. Full Clue Problem | ucup-team1198# | WA | 1ms | 3540kb | C++20 | 1.3kb | 2024-03-02 15:49:01 | 2024-03-02 15:49:02 |
Judging History
answer
#include <map>
#include <set>
#include <array>
#include <cmath>
#include <deque>
#include <bitset>
#include <random>
#include <string>
#include <vector>
#include <cassert>
#include <complex>
#include <iomanip>
#include <iostream>
#include <algorithm>
#include <unordered_map>
#include <unordered_set>
using namespace std;
int main() {
ios::sync_with_stdio(false);
cin.tie(0);
cout.tie(0);
int n;
cin >> n;
vector<vector<int>> tab(n + 2, vector<int>(n + 2, 0));
// tab[0][0] = 3;
// tab[n - 1][n - 1] = 3;
for (int i = 1; i <= n; ++i) {
tab[i][i - 1] = 2;
tab[i][i] = 2;
tab[i][i + 1] = 2;
}
tab[1][1] = tab[n][n] = 3;
for (int i = 1; i <= n; ++i) {
for (int j = 1; j <= n; ++j) {
cout << tab[i][j] << " ";
}
cout << '\n';
}
cout << '\n';
for (int t = -1; t < 2; t += 2) {
for (int i = 0; i < n; ++i) {
for (int j = 0; j < n; ++j) {
if (i == j || (i + t == j)) {
cout << 1 << " ";
} else {
cout << 0 << " ";
}
}
cout << '\n';
}
cout << '\n';
}
return 0;
}
详细
Test #1:
score: 0
Wrong Answer
time: 1ms
memory: 3540kb
input:
5
output:
3 2 0 0 0 2 2 2 0 0 0 2 2 2 0 0 0 2 2 2 0 0 0 2 3 1 0 0 0 0 1 1 0 0 0 0 1 1 0 0 0 0 1 1 0 0 0 0 1 1 1 1 0 0 0 0 1 1 0 0 0 0 1 1 0 0 0 0 1 1 0 0 0 0 1
result:
wrong answer (2, 0) doesn't satisfy with clues