結果

問題 No.739 大事なことなので2度言います
ユーザー dyechidyechi
提出日時 2019-03-28 15:20:35
言語 PHP
(8.3.4)
結果
WA  
実行時間 -
コード長 314 bytes
コンパイル時間 2,285 ms
コンパイル使用メモリ 30,520 KB
実行使用メモリ 30,768 KB
最終ジャッジ日時 2024-04-21 00:30:54
合計ジャッジ時間 3,409 ms
ジャッジサーバーID
(参考情報)
judge2 / judge1
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 AC 40 ms
30,768 KB
testcase_02 AC 38 ms
30,336 KB
testcase_03 AC 37 ms
30,696 KB
testcase_04 AC 38 ms
30,644 KB
testcase_05 AC 39 ms
30,456 KB
testcase_06 WA -
testcase_07 AC 39 ms
30,360 KB
testcase_08 AC 39 ms
30,728 KB
testcase_09 AC 39 ms
30,544 KB
testcase_10 AC 40 ms
30,644 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
No syntax errors detected in Main.php

ソースコード

diff #

<?php
$s = trim(fgets(STDIN));

if (strlen($s) % 2 == 0) {
    $previous_word = substr($s, 0, strlen($s)/2);
    $after_word = substr($s, strlen($s)/2);
    
    if ($previous_word === $after_word) {
           echo "YES".PHP_EOL;
    } else {
        echo "YES".PHP_EOL;
    }
} else {
    echo "NO".PHP_EOL;
}
?>
0