123456789101112131415161718 |
- /**
- * Created by iyasuwatts on 10/17/17.
- */
- import java.util.*;
- public class Main {
-
- public static void main(String[] args){
- Scanner input = new Scanner(System.in);
- int number = input.nextInt();
- int sum=0;
-
- for (int x=1; x<=number; x++){
- sum += x;
- }
- System.out.println(sum);
- }
- }
|