結果
問題 |
No.480 合計
|
ユーザー |
|
提出日時 | 2018-03-16 16:55:59 |
言語 | Java (openjdk 23) |
結果 |
AC
|
実行時間 | 135 ms / 2,000 ms |
コード長 | 379 bytes |
コンパイル時間 | 2,195 ms |
コンパイル使用メモリ | 74,668 KB |
実行使用メモリ | 41,600 KB |
最終ジャッジ日時 | 2024-12-21 14:30:20 |
合計ジャッジ時間 | 5,988 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 22 |
ソースコード
import java.util.Scanner; class Main { public static void main(String args[]) { Scanner scanner = new Scanner(System.in); String input = scanner.nextLine(); int num = Integer.parseInt(input); int sum = 0; for(int i = 1; i <= num; i++){ sum += i; } System.out.println(sum); scanner.close(); } }