結果

問題 No.9008 空白区切りで与えられる数値データの合計値を求める(テスト用)
ユーザー ribenngeribennge
提出日時 2018-08-21 10:33:02
言語 Java21
(openjdk 21)
結果
AC  
実行時間 839 ms / 2,000 ms
コード長 277 bytes
コンパイル時間 4,007 ms
コンパイル使用メモリ 71,648 KB
実行使用メモリ 65,552 KB
最終ジャッジ日時 2023-08-21 01:06:18
合計ジャッジ時間 12,903 ms
ジャッジサーバーID
(参考情報)
judge14 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 120 ms
55,752 KB
testcase_01 AC 121 ms
55,672 KB
testcase_02 AC 120 ms
55,928 KB
testcase_03 AC 121 ms
55,808 KB
testcase_04 AC 121 ms
56,424 KB
testcase_05 AC 132 ms
55,768 KB
testcase_06 AC 185 ms
56,572 KB
testcase_07 AC 279 ms
59,944 KB
testcase_08 AC 476 ms
60,300 KB
testcase_09 AC 526 ms
60,196 KB
testcase_10 AC 776 ms
65,212 KB
testcase_11 AC 789 ms
64,812 KB
testcase_12 AC 795 ms
64,864 KB
testcase_13 AC 823 ms
64,724 KB
testcase_14 AC 825 ms
65,552 KB
testcase_15 AC 833 ms
65,512 KB
testcase_16 AC 839 ms
64,640 KB
testcase_17 AC 118 ms
56,176 KB
testcase_18 AC 124 ms
56,152 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;

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