結果
問題 | No.81 すべて足すだけの簡単なお仕事です。 |
ユーザー |
![]() |
提出日時 | 2014-12-13 09:35:01 |
言語 | Java (openjdk 23) |
結果 |
AC
|
実行時間 | 150 ms / 5,000 ms |
コード長 | 343 bytes |
コンパイル時間 | 2,306 ms |
コンパイル使用メモリ | 74,680 KB |
実行使用メモリ | 42,208 KB |
最終ジャッジ日時 | 2024-07-22 16:28:30 |
合計ジャッジ時間 | 7,483 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 30 |
ソースコード
import java.math.*; import java.util.*; public class Main { public static void main(String[] args) { Scanner sc = new Scanner(System.in); int n=sc.nextInt(); BigDecimal ans = new BigDecimal("0"); for(int i=0;i<n;i++){ String d =sc.next(); ans=ans.add(new BigDecimal(d)); } System.out.printf("%.10f",ans); } }