結果

問題 No.700 LOVE
ユーザー papinianuspapinianus
提出日時 2021-05-29 04:17:28
言語 PHP
(8.3.4)
結果
AC  
実行時間 38 ms / 2,000 ms
コード長 263 bytes
コンパイル時間 2,830 ms
コンパイル使用メモリ 30,236 KB
実行使用メモリ 31,384 KB
最終ジャッジ日時 2024-04-25 04:28:58
合計ジャッジ時間 4,294 ms
ジャッジサーバーID
(参考情報)
judge1 / judge3
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 38 ms
31,024 KB
testcase_01 AC 36 ms
31,152 KB
testcase_02 AC 35 ms
30,976 KB
testcase_03 AC 37 ms
31,136 KB
testcase_04 AC 35 ms
31,128 KB
testcase_05 AC 35 ms
30,932 KB
testcase_06 AC 34 ms
31,384 KB
testcase_07 AC 36 ms
30,972 KB
testcase_08 AC 35 ms
31,080 KB
testcase_09 AC 35 ms
31,200 KB
testcase_10 AC 36 ms
31,208 KB
testcase_11 AC 34 ms
30,980 KB
testcase_12 AC 35 ms
30,920 KB
testcase_13 AC 35 ms
31,016 KB
testcase_14 AC 37 ms
30,828 KB
testcase_15 AC 35 ms
31,160 KB
testcase_16 AC 36 ms
31,072 KB
testcase_17 AC 36 ms
31,296 KB
testcase_18 AC 35 ms
31,372 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
No syntax errors detected in Main.php

ソースコード

diff #

<?php
declare(strict_types=1);
[$n,$m] = explode(" ", trim(fgets(STDIN)));
$needle = "LOVE";
while($n) {
    $hasLove = strpos(trim(fgets(STDIN)),$needle);
    if($hasLove !== false) {
        echo "YES".PHP_EOL;
        exit;
    }
    $n--;
}
echo "NO".PHP_EOL;
0