結果
問題 | No.350 d=vt |
ユーザー | kenji_shioya |
提出日時 | 2016-06-02 18:19:35 |
言語 | Java (openjdk 23) |
結果 |
AC
|
実行時間 | 149 ms / 2,000 ms |
コード長 | 486 bytes |
コンパイル時間 | 3,896 ms |
コンパイル使用メモリ | 75,600 KB |
実行使用メモリ | 41,756 KB |
最終ジャッジ日時 | 2024-10-05 04:55:59 |
合計ジャッジ時間 | 6,091 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 12 |
ソースコード
import java.util.*; import java.text.*; public class Exercise49{ public static void main (String[] args){ Scanner sc = new Scanner(System.in); double v = sc.nextDouble() + 0.00001; int t = sc.nextInt(); DecimalFormat df = new DecimalFormat("#.#####"); String numStr = df.format(v); String x = numStr.substring(2, 6); String trimedStr = x.replaceFirst("^0+", ""); int vd = Integer.parseInt(trimedStr); System.out.println(vd * t / 10000); } }