結果

問題 No.739 大事なことなので2度言います
ユーザー x87asdfx87asdf
提出日時 2018-10-15 03:01:48
言語 Java21
(openjdk 21)
結果
AC  
実行時間 121 ms / 2,000 ms
コード長 381 bytes
コンパイル時間 2,259 ms
コンパイル使用メモリ 72,112 KB
実行使用メモリ 56,328 KB
最終ジャッジ日時 2023-08-13 01:29:47
合計ジャッジ時間 4,325 ms
ジャッジサーバーID
(参考情報)
judge14 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 121 ms
55,684 KB
testcase_01 AC 118 ms
55,808 KB
testcase_02 AC 115 ms
55,568 KB
testcase_03 AC 115 ms
55,628 KB
testcase_04 AC 116 ms
55,604 KB
testcase_05 AC 114 ms
55,636 KB
testcase_06 AC 109 ms
55,700 KB
testcase_07 AC 113 ms
56,208 KB
testcase_08 AC 116 ms
55,504 KB
testcase_09 AC 114 ms
55,876 KB
testcase_10 AC 115 ms
56,328 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.*;

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        String str = sc.next();
        int length = str.length()/2;

        if( str.substring(0, length).equals(str.substring(length)) ) {
            System.out.println("YES");
        }else{
            System.out.println("NO");
        }
    }
}
0