結果
問題 | No.739 大事なことなので2度言います |
ユーザー |
![]() |
提出日時 | 2019-08-18 11:50:46 |
言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
結果 |
AC
|
実行時間 | 2 ms / 2,000 ms |
コード長 | 407 bytes |
コンパイル時間 | 706 ms |
コンパイル使用メモリ | 73,904 KB |
実行使用メモリ | 5,248 KB |
最終ジャッジ日時 | 2024-10-01 13:51:57 |
合計ジャッジ時間 | 1,266 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 4 |
other | AC * 7 |
ソースコード
#include<iostream> #include<algorithm> #include <vector> #include<cmath> using namespace std; int main() { string S; cin >> S; if (S.size() % 2 != 0) { cout << "NO" << endl; } else { int cnt = 0; for (int ia = 0; ia < S.size() / 2; ia++) { if (S.at(ia) != S.at(ia + S.size() / 2)) { cnt++; } } if (cnt) { cout << "NO" << endl; } if (!cnt) { cout << "YES" << endl; } } }