結果

問題 No.480 合計
ユーザー FVRChanFVRChan
提出日時 2017-10-02 21:29:21
言語 Java21
(openjdk 21)
結果
AC  
実行時間 125 ms / 2,000 ms
コード長 249 bytes
コンパイル時間 3,142 ms
コンパイル使用メモリ 71,432 KB
実行使用メモリ 56,212 KB
最終ジャッジ日時 2023-08-21 02:02:06
合計ジャッジ時間 7,003 ms
ジャッジサーバーID
(参考情報)
judge12 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 125 ms
53,724 KB
testcase_01 AC 124 ms
55,616 KB
testcase_02 AC 122 ms
55,540 KB
testcase_03 AC 124 ms
55,936 KB
testcase_04 AC 122 ms
55,908 KB
testcase_05 AC 123 ms
53,924 KB
testcase_06 AC 120 ms
55,800 KB
testcase_07 AC 123 ms
56,212 KB
testcase_08 AC 122 ms
55,392 KB
testcase_09 AC 122 ms
55,644 KB
testcase_10 AC 122 ms
55,564 KB
testcase_11 AC 123 ms
55,868 KB
testcase_12 AC 122 ms
55,796 KB
testcase_13 AC 123 ms
55,488 KB
testcase_14 AC 124 ms
55,696 KB
testcase_15 AC 123 ms
55,972 KB
testcase_16 AC 124 ms
56,004 KB
testcase_17 AC 123 ms
55,796 KB
testcase_18 AC 124 ms
55,952 KB
testcase_19 AC 124 ms
55,408 KB
testcase_20 AC 122 ms
55,496 KB
testcase_21 AC 124 ms
55,616 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;
public class Main{
	private static Scanner sc=new Scanner(System.in);
	public static void main(String args[])throws Exception{
		int n=sc.nextInt(),sum=0;
		for(int i=1;i<=n;i++){
			sum+=i;
		}System.out.println(sum);
	}
}
0