結果

問題 No.739 大事なことなので2度言います
ユーザー tentententen
提出日時 2020-12-09 09:21:52
言語 Java21
(openjdk 21)
結果
AC  
実行時間 134 ms / 2,000 ms
コード長 557 bytes
コンパイル時間 2,152 ms
コンパイル使用メモリ 74,120 KB
実行使用メモリ 57,576 KB
最終ジャッジ日時 2023-10-19 04:46:01
合計ジャッジ時間 4,474 ms
ジャッジサーバーID
(参考情報)
judge13 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 131 ms
57,520 KB
testcase_01 AC 133 ms
57,372 KB
testcase_02 AC 132 ms
57,244 KB
testcase_03 AC 131 ms
57,388 KB
testcase_04 AC 133 ms
57,380 KB
testcase_05 AC 128 ms
57,416 KB
testcase_06 AC 133 ms
57,576 KB
testcase_07 AC 134 ms
57,448 KB
testcase_08 AC 131 ms
55,252 KB
testcase_09 AC 133 ms
57,436 KB
testcase_10 AC 132 ms
57,372 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.*;

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        char[] arr = sc.next().toCharArray();
        if (arr.length % 2 == 0) {
            for (int i = 0; i < arr.length / 2; i++) {
                if (arr[i] != arr[arr.length / 2 + i]) {
                    System.out.println("NO");
                    return;
                }
            }
        } else {
            System.out.println("NO");
            return;
        }
        System.out.println("YES");
    }
}
0