結果

問題 No.26 シャッフルゲーム
ユーザー papinianuspapinianus
提出日時 2016-06-01 10:39:37
言語 PHP
(8.3.4)
結果
WA  
実行時間 -
コード長 234 bytes
コンパイル時間 2,325 ms
コンパイル使用メモリ 32,400 KB
実行使用メモリ 32,528 KB
最終ジャッジ日時 2024-04-16 22:22:08
合計ジャッジ時間 1,093 ms
ジャッジサーバーID
(参考情報)
judge3 / judge1
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 44 ms
31,180 KB
testcase_01 AC 43 ms
31,156 KB
testcase_02 AC 41 ms
30,972 KB
testcase_03 WA -
testcase_04 AC 41 ms
31,176 KB
testcase_05 WA -
testcase_06 AC 41 ms
31,172 KB
testcase_07 WA -
testcase_08 WA -
testcase_09 AC 41 ms
31,260 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
No syntax errors detected in Main.php

ソースコード

diff #

<?php
$curpos = trim(fgets(STDIN));
$count = trim(fgets(STDIN));
for($i = 0; $i < $count; $i++) {
    list($src, $dst) = explode(' ', trim(fgets(STDIN)));
    if($src == $curpos) {
        $curpos = $dst;
    }
}
echo $curpos.PHP_EOL;
0