結果
| 問題 |
No.3125 Make It Symmetry
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2025-04-25 21:26:48 |
| 言語 | C++23 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 588 bytes |
| コンパイル時間 | 857 ms |
| コンパイル使用メモリ | 85,920 KB |
| 実行使用メモリ | 7,844 KB |
| 最終ジャッジ日時 | 2025-04-25 21:26:56 |
| 合計ジャッジ時間 | 2,240 ms |
|
ジャッジサーバーID (参考情報) |
judge5 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 26 WA * 10 |
ソースコード
#include <iostream>
#include <cstdint>
#include <vector>
using namespace std;
static inline constexpr const char* solve(const uint32_t N, const vector<string>& A)
{
uint32_t count = 0;
for (uint32_t i = 0; i != N; ++i)
for (uint32_t j = 0; j != N / 2; ++j)
if (A[i][j] != A[i][(N - 1) - j])
++count;
if (count & 1) return "No";
else return "Yes";
}
int main()
{
cin.tie(nullptr);
ios::sync_with_stdio(false);
uint32_t N, i;
cin >> N;
vector<string> A(N);
for (i = 0; i != N; ++i)
{
A[i].reserve(N);
cin >> A[i];
}
cout << solve(N, A) << '\n';
return 0;
}