結果

問題 No.293 4>7の世界
ユーザー benben
提出日時 2015-11-19 20:30:41
言語 PHP
(8.3.4)
結果
WA  
実行時間 -
コード長 302 bytes
コンパイル時間 1,314 ms
コンパイル使用メモリ 18,488 KB
実行使用メモリ 19,060 KB
最終ジャッジ日時 2023-10-11 18:06:07
合計ジャッジ時間 1,494 ms
ジャッジサーバーID
(参考情報)
judge15 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 15 ms
18,784 KB
testcase_01 AC 16 ms
19,028 KB
testcase_02 AC 15 ms
18,804 KB
testcase_03 WA -
testcase_04 AC 16 ms
18,804 KB
testcase_05 AC 16 ms
19,044 KB
testcase_06 AC 16 ms
18,992 KB
testcase_07 AC 15 ms
18,892 KB
testcase_08 AC 16 ms
18,852 KB
testcase_09 WA -
testcase_10 AC 16 ms
18,828 KB
testcase_11 AC 15 ms
18,920 KB
testcase_12 AC 16 ms
19,060 KB
testcase_13 AC 16 ms
18,892 KB
testcase_14 AC 16 ms
18,940 KB
testcase_15 WA -
testcase_16 AC 16 ms
18,828 KB
testcase_17 AC 15 ms
19,004 KB
testcase_18 AC 16 ms
19,012 KB
testcase_19 AC 15 ms
18,824 KB
testcase_20 AC 16 ms
19,052 KB
testcase_21 AC 16 ms
19,016 KB
testcase_22 AC 15 ms
18,804 KB
testcase_23 AC 15 ms
18,932 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
No syntax errors detected in Main.php

ソースコード

diff #

<?php
fscanf(STDIN, "%d %d", $b, $c);

$tmp_b = $b;
$tmp_c = $c;

if (preg_match("/4|7/", $b) && preg_match("/4|7/", $c)){
    $list = array("4"=>"7", "7"=>"4");
    $tmp_b = strtr($b, $list);
    $tmp_c = strtr($c, $list);
}



if($tmp_b < $tmp_c) echo $c;
if($tmp_c < $tmp_b) echo $b;

echo "\n";
?>
0