結果

問題 No.9009 改行区切りで与えられる数値データの合計値を求める(テスト用)
ユーザー LeonardoneLeonardone
提出日時 2016-09-08 19:18:21
言語 Java21
(openjdk 21)
結果
AC  
実行時間 750 ms / 3,000 ms
コード長 366 bytes
コンパイル時間 3,248 ms
コンパイル使用メモリ 71,868 KB
実行使用メモリ 64,532 KB
最終ジャッジ日時 2023-08-26 16:43:46
合計ジャッジ時間 12,007 ms
ジャッジサーバーID
(参考情報)
judge12 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 109 ms
55,924 KB
testcase_01 AC 110 ms
55,752 KB
testcase_02 AC 107 ms
56,696 KB
testcase_03 AC 104 ms
55,408 KB
testcase_04 AC 112 ms
55,864 KB
testcase_05 AC 120 ms
56,008 KB
testcase_06 AC 169 ms
55,540 KB
testcase_07 AC 254 ms
60,380 KB
testcase_08 AC 425 ms
60,124 KB
testcase_09 AC 509 ms
60,732 KB
testcase_10 AC 730 ms
64,060 KB
testcase_11 AC 715 ms
63,972 KB
testcase_12 AC 723 ms
64,240 KB
testcase_13 AC 704 ms
64,056 KB
testcase_14 AC 711 ms
64,036 KB
testcase_15 AC 735 ms
64,192 KB
testcase_16 AC 750 ms
64,532 KB
testcase_17 AC 107 ms
55,812 KB
testcase_18 AC 107 ms
55,556 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.lang.*;
import java.util.*;

public class Solve
{
    public static void main(String[] args)
    {
        Scanner in = new Scanner(System.in);
        
        int n = in.nextInt();
        long sum = 0L;
        
        for (int i = 0; i < n; i++)
        {
            sum += in.nextLong();
        }
        
        System.out.println(sum);
    }
}
0