結果

問題 No.480 合計
ユーザー Ga-Chi-Mu-ChiGa-Chi-Mu-Chi
提出日時 2018-10-18 17:34:08
言語 Java21
(openjdk 21)
結果
AC  
実行時間 136 ms / 2,000 ms
コード長 303 bytes
コンパイル時間 3,516 ms
コンパイル使用メモリ 74,228 KB
実行使用メモリ 41,604 KB
最終ジャッジ日時 2024-04-24 10:58:09
合計ジャッジ時間 7,695 ms
ジャッジサーバーID
(参考情報)
judge1 / judge5
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 134 ms
41,236 KB
testcase_01 AC 115 ms
40,232 KB
testcase_02 AC 131 ms
41,440 KB
testcase_03 AC 131 ms
41,180 KB
testcase_04 AC 118 ms
40,052 KB
testcase_05 AC 131 ms
41,020 KB
testcase_06 AC 131 ms
41,180 KB
testcase_07 AC 136 ms
41,280 KB
testcase_08 AC 131 ms
41,412 KB
testcase_09 AC 132 ms
41,344 KB
testcase_10 AC 130 ms
41,364 KB
testcase_11 AC 130 ms
41,528 KB
testcase_12 AC 129 ms
41,052 KB
testcase_13 AC 130 ms
41,340 KB
testcase_14 AC 118 ms
40,088 KB
testcase_15 AC 131 ms
41,196 KB
testcase_16 AC 131 ms
41,604 KB
testcase_17 AC 131 ms
41,164 KB
testcase_18 AC 134 ms
41,428 KB
testcase_19 AC 132 ms
41,292 KB
testcase_20 AC 130 ms
41,188 KB
testcase_21 AC 130 ms
41,328 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;
public class HELLO {

	public static void main(String[] args) {
		// TODO Auto-generated method stub
		Scanner stdIn = new Scanner (System.in);
		int n = stdIn.nextInt();
		int total = 0;
		for(int i = 1; i<=n; i++) {
			total = total + i;
		}
		System.out.print(total);
	}

}
0