結果
問題 | No.2099 [Cherry Alpha B] Time Machine |
ユーザー |
![]() |
提出日時 | 2022-10-14 22:20:31 |
言語 | Perl (5.40.0) |
結果 |
RE
|
実行時間 | - |
コード長 | 319 bytes |
コンパイル時間 | 314 ms |
コンパイル使用メモリ | 7,068 KB |
実行使用メモリ | 6,944 KB |
最終ジャッジ日時 | 2024-06-26 15:26:49 |
合計ジャッジ時間 | 5,789 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 63 RE * 9 |
コンパイルメッセージ
Warning: Use of "int" without parentheses is ambiguous at Main.pl line 5. Main.pl syntax OK
ソースコード
$t=<>; ($x,$a)=glob<>; ($y,$b)=glob<>; if($t<0){ $q=int+(1-$t)/$b+1; $c+=$q*$y; $t+=$q*$b; die if $t>=$b; # RE } 0 while $t<0; # TLE { $q=int$t/$a; $c+=$q*$x; $t-=$q*$a; $d=$c+$t; } while(1){ $c+=$y; $t+=$b; $q=int$t/$a; $c+=$q*$x; $t-=$q*$a; if($c>$d){ last; } if($d>$c+$t){ $d=$c+$t; } } print$d;