結果

問題 No.316 もっと刺激的なFizzBuzzをください
ユーザー Ruizi_LuigiRuizi_Luigi
提出日時 2015-12-20 23:25:30
言語 PHP
(8.3.4)
結果
RE  
実行時間 -
コード長 362 bytes
コンパイル時間 6,106 ms
コンパイル使用メモリ 32,340 KB
実行使用メモリ 114,396 KB
最終ジャッジ日時 2023-10-17 14:38:04
合計ジャッジ時間 14,398 ms
ジャッジサーバーID
(参考情報)
judge15 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 156 ms
69,936 KB
testcase_01 RE -
testcase_02 RE -
testcase_03 AC 45 ms
32,568 KB
testcase_04 RE -
testcase_05 RE -
testcase_06 AC 46 ms
32,568 KB
testcase_07 AC 45 ms
32,568 KB
testcase_08 AC 45 ms
32,572 KB
testcase_09 RE -
testcase_10 AC 53 ms
36,572 KB
testcase_11 AC 46 ms
32,568 KB
testcase_12 AC 49 ms
34,524 KB
testcase_13 AC 47 ms
32,568 KB
testcase_14 AC 48 ms
34,524 KB
testcase_15 AC 49 ms
34,524 KB
testcase_16 AC 129 ms
69,568 KB
testcase_17 AC 49 ms
34,524 KB
testcase_18 AC 54 ms
38,620 KB
testcase_19 AC 91 ms
55,004 KB
testcase_20 AC 86 ms
52,956 KB
testcase_21 AC 104 ms
55,004 KB
testcase_22 AC 47 ms
32,568 KB
testcase_23 AC 55 ms
38,620 KB
testcase_24 AC 50 ms
34,524 KB
testcase_25 AC 181 ms
72,688 KB
testcase_26 AC 45 ms
32,568 KB
testcase_27 AC 45 ms
32,568 KB
testcase_28 AC 50 ms
34,524 KB
testcase_29 AC 58 ms
38,620 KB
testcase_30 AC 312 ms
114,396 KB
testcase_31 AC 155 ms
62,352 KB
testcase_32 RE -
testcase_33 RE -
testcase_34 AC 104 ms
55,004 KB
testcase_35 AC 227 ms
89,820 KB
testcase_36 RE -
権限があれば一括ダウンロードができます
コンパイルメッセージ
No syntax errors detected in Main.php

ソースコード

diff #

<?php


$n = trim(fgets(STDIN));

list($a,$b,$c) = explode(" ", trim(fgets(STDIN)));

$list = array();
$applied = 1;
while($a * $applied <= $n) {
	$list[] = $a * $applied++;
}

$applied = 1;
while($b * $applied <= $n) {
	$list[] = $b * $applied++;
}
$applied = 1;
while($c * $applied <= $n) {
	$list[] = $c * $applied++;
}
echo count(array_unique($list)) . "\n";
0