結果

問題 No.1935 Water Simulation
ユーザー tailstails
提出日時 2022-05-13 21:27:46
言語 Perl
(5.26.3)
結果
WA  
(最新)
AC  
(最初)
実行時間 -
コード長 198 bytes
コンパイル時間 425 ms
使用メモリ 7,608 KB
最終ジャッジ日時 2023-02-21 18:37:48
合計ジャッジ時間 2,082 ms
ジャッジサーバーID
(参考情報)
judge13 / judge11
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
使用メモリ
testcase_00 WA -
testcase_01 WA -
testcase_02 AC 6 ms
6,196 KB
testcase_03 AC 6 ms
6,256 KB
testcase_04 AC 6 ms
6,204 KB
testcase_05 AC 6 ms
6,244 KB
testcase_06 AC 6 ms
6,244 KB
testcase_07 AC 5 ms
6,180 KB
testcase_08 AC 6 ms
6,200 KB
testcase_09 AC 6 ms
6,240 KB
testcase_10 AC 6 ms
6,200 KB
testcase_11 AC 5 ms
6,248 KB
testcase_12 AC 6 ms
6,268 KB
testcase_13 AC 6 ms
6,264 KB
testcase_14 AC 6 ms
6,200 KB
testcase_15 AC 6 ms
6,252 KB
testcase_16 AC 6 ms
6,244 KB
testcase_17 AC 6 ms
6,276 KB
testcase_18 AC 6 ms
6,240 KB
testcase_19 AC 6 ms
6,204 KB
testcase_20 AC 6 ms
6,248 KB
testcase_21 AC 6 ms
6,276 KB
testcase_22 AC 6 ms
6,204 KB
testcase_23 AC 6 ms
6,276 KB
testcase_24 AC 6 ms
6,184 KB
testcase_25 AC 6 ms
6,252 KB
testcase_26 AC 6 ms
6,168 KB
testcase_27 AC 6 ms
6,260 KB
testcase_28 AC 6 ms
6,188 KB
testcase_29 AC 6 ms
6,168 KB
testcase_30 AC 6 ms
6,200 KB
testcase_31 AC 6 ms
6,208 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Main.pl syntax OK

ソースコード

diff #

(@v[0..3],$n)=glob<>;
@a=($v[0],0,0,0);
$n=$n%88if$n>88;
for$i(0..$n-1){
	$a[$i+1&3]+=$a[$i&3],$a[$i&3]=0;
	$a[$i&3]=$a[$i+1&3]-$v[$i+1&3],$a[$i+1&3]=$v[$i+1&3]if$a[$i+1&3]>$v[$i+1&3];
}
print"@a";
0