結果

問題 No.722 100×100=1000
ユーザー lewinlewin
提出日時 2019-06-03 12:47:18
言語 PHP
(8.3.4)
結果
WA  
実行時間 -
コード長 468 bytes
コンパイル時間 105 ms
コンパイル使用メモリ 30,960 KB
実行使用メモリ 36,376 KB
最終ジャッジ日時 2024-04-20 16:20:27
合計ジャッジ時間 4,396 ms
ジャッジサーバーID
(参考情報)
judge2 / judge5
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 46 ms
36,376 KB
testcase_01 AC 49 ms
31,332 KB
testcase_02 AC 45 ms
31,360 KB
testcase_03 WA -
testcase_04 AC 44 ms
31,212 KB
testcase_05 AC 45 ms
31,248 KB
testcase_06 AC 43 ms
31,196 KB
testcase_07 AC 45 ms
31,488 KB
testcase_08 AC 44 ms
30,908 KB
testcase_09 AC 45 ms
31,488 KB
testcase_10 AC 42 ms
31,156 KB
testcase_11 AC 42 ms
31,328 KB
testcase_12 AC 43 ms
31,152 KB
testcase_13 TLE -
testcase_14 -- -
testcase_15 -- -
testcase_16 -- -
testcase_17 -- -
testcase_18 -- -
testcase_19 -- -
testcase_20 -- -
testcase_21 -- -
testcase_22 -- -
testcase_23 -- -
testcase_24 -- -
testcase_25 -- -
testcase_26 -- -
testcase_27 -- -
testcase_28 -- -
testcase_29 -- -
testcase_30 -- -
権限があれば一括ダウンロードができます
コンパイルメッセージ
No syntax errors detected in Main.php

ソースコード

diff #

<?php

pro2();

function pro2()
{
	$str = trim(fgets(STDIN));
	list ($a, $b) = explode(' ', $str);

	$res = $a % 100 == 0 && $b % 100 == 0 && test($a) && test($b);
	if ($res) {
		$answer = $a * $b / 10;
	} else {
		$answer = $a * $b;
		if ($answer < -99999999 || $answer > 99999999) {
			$answer = 'E';
		}
	}

	echo $answer . PHP_EOL;
}

function test($num)
{
	while (true) {
		$num /= 10;
		if ($num % 10 != 0) {
			break;
		}
	}

	return ($num >= 1 && $num <= 9);
}
0