結果
| 問題 |
No.739 大事なことなので2度言います
|
| コンテスト | |
| ユーザー |
29da164
|
| 提出日時 | 2020-07-23 09:30:37 |
| 言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
AC
|
| 実行時間 | 2 ms / 2,000 ms |
| コード長 | 408 bytes |
| コンパイル時間 | 619 ms |
| コンパイル使用メモリ | 65,932 KB |
| 実行使用メモリ | 6,944 KB |
| 最終ジャッジ日時 | 2024-06-23 17:22:18 |
| 合計ジャッジ時間 | 1,069 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 4 |
| other | AC * 7 |
ソースコード
#include <iostream>
int main(void){
std::string a;
std::cin >> a;
const char* ca = a.c_str();
int count=0;
if(a.length()%2!=0) std::cout << "NO" << std::endl;
else{
for(int i=0;i<a.length()/2;i++){
if(ca[i]!=ca[i+a.length()/2]){
std::cout <<"NO" << std::endl;
break;
}
else count++;
}
if(count==a.length()/2) std::cout <<"YES" << std::endl;
}
}
29da164