結果

問題 No.369 足し間違い
ユーザー ぴろずぴろず
提出日時 2016-07-18 22:00:57
言語 Java21
(openjdk 21)
結果
AC  
実行時間 247 ms / 2,000 ms
コード長 287 bytes
コンパイル時間 1,958 ms
コンパイル使用メモリ 73,948 KB
実行使用メモリ 47,164 KB
最終ジャッジ日時 2024-04-23 16:35:50
合計ジャッジ時間 4,030 ms
ジャッジサーバーID
(参考情報)
judge2 / judge5
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 133 ms
41,756 KB
testcase_01 AC 132 ms
41,232 KB
testcase_02 AC 129 ms
41,380 KB
testcase_03 AC 140 ms
41,436 KB
testcase_04 AC 247 ms
46,584 KB
testcase_05 AC 196 ms
43,108 KB
testcase_06 AC 237 ms
46,604 KB
testcase_07 AC 243 ms
47,164 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

package no369;

import java.util.Scanner;

public class Main {

	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 - sc.nextInt());
	}

}
0