結果

問題 No.144 エラトステネスのざる
ユーザー %20%20
提出日時 2017-09-07 21:06:38
言語 Perl
(5.38.2)
結果
WA  
実行時間 -
コード長 103 bytes
コンパイル時間 371 ms
コンパイル使用メモリ 5,888 KB
実行使用メモリ 60,032 KB
最終ジャッジ日時 2024-04-25 01:42:39
合計ジャッジ時間 15,298 ms
ジャッジサーバーID
(参考情報)
judge2 / judge3
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 AC 7 ms
6,016 KB
testcase_02 WA -
testcase_03 AC 6 ms
5,888 KB
testcase_04 AC 6 ms
6,016 KB
testcase_05 AC 6 ms
5,888 KB
testcase_06 AC 6 ms
6,016 KB
testcase_07 WA -
testcase_08 WA -
testcase_09 WA -
testcase_10 WA -
testcase_11 WA -
testcase_12 WA -
testcase_13 TLE -
testcase_14 TLE -
testcase_15 TLE -
testcase_16 TLE -
testcase_17 TLE -
testcase_18 TLE -
testcase_19 TLE -
権限があれば一括ダウンロードができます
コンパイルメッセージ
Name "main::P" used only once: possible typo at Main.pl line 2.
Main.pl syntax OK

ソースコード

diff #

($N,$p)=glob<>;
$P=1-$p;
for(2..$N){
	$i=$_;
	++$_[$i+=$_]while$i<$N;
#	$x+=$P**$_[$_]
	++$x
}
print$x
0