Thanks to drizzlecrj's suggestion, I turned to hdu for the primary practice. Hnu was another choice, but the server is too poor that a submitted problem is showed "wariting" all the time.

Problem Description
Hey, welcome to HDOJ(Hangzhou Dianzi University Online Judge).

In this problem, your task is to calculate SUM(n) = 1 + 2 + 3 + ... + n.

Input

The input will consist of a series of integers n, one integer per line.

Output

For each case, output SUM(n) in one line, followed by a blank line. You may assume the result will be in the range of 32-bit signed integer.

Sample Input

1
100
Sample Output

1
5050
Problem 1001: Sum Problem#include <stdio.h>
Problem 1001: Sum Problem
Problem 1001: Sum Problem
int main()
}

Summary:
Easy as it may seem, I am starting off.

相关文章:

  • 2022-12-23
  • 2022-01-05
  • 2021-04-07
  • 2021-09-28
  • 2021-05-18
  • 2021-12-03
  • 2021-09-07
猜你喜欢
  • 2021-06-07
  • 2022-01-10
  • 2021-10-27
  • 2022-12-23
  • 2022-12-23
  • 2021-04-22
  • 2022-12-23
相关资源
相似解决方案