結果

問題 No.480 合計
ユーザー ShotaroSuzuShotaroSuzu
提出日時 2020-12-15 22:28:42
言語 Java21
(openjdk 21)
結果
AC  
実行時間 136 ms / 2,000 ms
コード長 335 bytes
コンパイル時間 4,517 ms
コンパイル使用メモリ 75,488 KB
実行使用メモリ 57,788 KB
最終ジャッジ日時 2023-10-20 06:51:00
合計ジャッジ時間 7,633 ms
ジャッジサーバーID
(参考情報)
judge12 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 133 ms
57,424 KB
testcase_01 AC 136 ms
57,196 KB
testcase_02 AC 131 ms
57,128 KB
testcase_03 AC 130 ms
57,648 KB
testcase_04 AC 132 ms
57,136 KB
testcase_05 AC 131 ms
57,448 KB
testcase_06 AC 132 ms
57,236 KB
testcase_07 AC 130 ms
57,308 KB
testcase_08 AC 125 ms
57,208 KB
testcase_09 AC 113 ms
55,112 KB
testcase_10 AC 128 ms
57,448 KB
testcase_11 AC 124 ms
57,604 KB
testcase_12 AC 128 ms
57,268 KB
testcase_13 AC 124 ms
57,264 KB
testcase_14 AC 129 ms
57,788 KB
testcase_15 AC 126 ms
57,472 KB
testcase_16 AC 124 ms
57,476 KB
testcase_17 AC 131 ms
57,140 KB
testcase_18 AC 132 ms
57,472 KB
testcase_19 AC 128 ms
57,484 KB
testcase_20 AC 125 ms
57,684 KB
testcase_21 AC 126 ms
57,604 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

package yukicoder.tutorial.sum.bywhitespace;

import java.util.Scanner;
import java.util.stream.IntStream;

public class Main {

	@SuppressWarnings("resource")
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int length = sc.nextInt();
		System.out.println(IntStream.range(1, length + 1).sum());
	}
}
0