Problem:


Score : 100 points

Problem Statement

There are N children in AtCoder Kindergarten. Mr. Evi will arrange the children in a line, then give 1 candy to the first child in the line, 2 candies to the second child, ..., N candies to the N-th child. How many candies will be necessary in total?

Constraints

1≦N≦100

Input

The input is given from Standard Input in the following format:

N

Output

Print the necessary number of candies in total.

Sample Input 1

3

Sample Output 1

6

The answer is 1+2+3=6.

Sample Input 2

10

Sample Output 2

55

The sum of the integers from 1 to 10 is 55.

Sample Input 3

1

Sample Output 3

1

Only one child. The answer is 1 in this case.



Sample input:
3


Sample output:
6

Submission status: Accepted

Solution code:
N = int(input())

ans =int(N*(N+1)/2)

print(ans)

Submission status: Accepted

Solution code:
import sys, math

def input():
    return sys.stdin.readline()[:-1]

def main():
    N = int(input())
    print((N*(N+1))//2)

if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
n = int(input())
total = n
for i in range(n):
    total += i

print(total)

Submission status: Accepted

Solution code:
N = int(input())
total = N
for i in range(N):
  total += i

print(total)

Submission status: Accepted

Solution code:
def main():
    children_num = int(input())
    print(children_num * (children_num + 1) // 2)


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
N = int(input())
print( (N * (N+1)) // 2 )

Submission status: Accepted

Solution code:
n = int(input())

ans = 0 
for num in range(1, n+1):
  ans += num

print(ans)

Submission status: Accepted

Solution code:
n = int(input())

print(int(0.5 * n * (n+1)))

Submission status: Accepted

Solution code:
print(sum([i+1 for i in range(int(input()))]))

Submission status: Accepted

Solution code:
n=int(input())
m=0
for i in range(1,n+1):
  m+=i
print(m)

Submission status: Accepted

Solution code:
n=int(input())
print((n*(n+1))//2)

Submission status: Accepted

Solution code:
N = int(input())
n = 0
for i in range(1, N+1):
    n += i
    
print(n)

Submission status: Accepted

Solution code:
n = int(input())
if n == 1:
  print(n)
else:
  print(int(n * (n + 1) / 2))

Submission status: Accepted

Solution code:
print(sum(i for i in range(1,int(input())+1)))

Submission status: Accepted

Solution code:
def souwa(num):
    sum = 0
    for i in range(num):
        sum += (i + 1)
    return sum


num = int(input())
answer = souwa(num)
print(answer)

Submission status: Accepted

Solution code:
n=int(input())
s=0
for i in range(1,n+1):
    s+=i

print(s)

Submission status: Accepted

Solution code:
a = int(input())

print(sum(range(1, a + 1)))

Submission status: Accepted

Solution code:
# coding: utf-8
 
 
def main():
 
    in_ninzu = int(input())
    
    # '/'で割ると小数点付きの表示になるので’//’で商を求めると整数になる
    in_candy = in_ninzu * (in_ninzu + 1) // 2
    
    print(in_candy)
  
    return 0
 
 
if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
a = int(input())

print(int(0.5 * a * (2 + (a - 1) * 1)))

Submission status: Accepted

Solution code:
#A - キャンディーとN人の子供イージー

#入力N
N = int(input())

candy = 0
for n in range(N):
  candy += (n+1)
  
print(candy)

Submission status: Accepted

Solution code:
N = int(input())
print(((N + 1)*N)// 2)

Submission status: Accepted

Solution code:
n = int(input())
sum=0
for i in range(1,n+1):
    sum+=i
print(sum)

Submission status: Accepted

Solution code:
a = int(input())
print((a+1)*a//2)

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
import sys


def solve(N: int):
    print(N * (N + 1) // 2)


def main():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    N = int(next(tokens))  # type: int
    solve(N)


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
s = int(input())
count = 0
for i in range(s):
    count += s - i
print(count)

Submission status: Accepted

Solution code:
N = int(input())


def func(x):
    if x == 1:
        return 1
    else:
        return func(x - 1) + x


print(func(N))

Submission status: Accepted

Solution code:
n=int(input())
ans=0
for i in range(n+1):
    ans=ans+i
print(ans)

Submission status: Accepted

Solution code:
child=int(input())
ame=0

while child!=0:
    ame=ame+child
    child-=1

print(ame)

Submission status: Accepted

Solution code:
ans = 0
for i in range(int(input())):
    ans += i + 1

print(ans)

Submission status: Accepted

Solution code:
N = int(input())
a = (N * (N + 1)) // 2
print(a)

Submission status: Accepted

Solution code:
text = int(input())
answer = 0
for i in range(text):
  answer += i + 1
print(answer)

Submission status: Accepted

Solution code:
N = int(input())
print((N**2+N)//2)

Submission status: Accepted

Solution code:
N = int(input())
print((N*(N+1)//2))

Submission status: Accepted

Solution code:
n=int(input())
a = 0
for i in range(1,n+1):
    a += i
print(a)

Submission status: Accepted

Solution code:
n = int(input())
ans=0
for i in range(n):
    ans+=i+1
print(ans)

Submission status: Accepted

Solution code:
N = int(input())
print(sum(list(range(1,N+1))))

Submission status: Accepted

Solution code:
#ABC043 A
n = int(input())
print(n * (n + 1) // 2)

Submission status: Accepted

Solution code:
print(sum([i+1 for i in range(int(input()))]))

Submission status: Accepted

Solution code:
N = int(input())
print(int((N * (N+1)) / 2))

Submission status: Accepted

Solution code:
N = int(input())
sum = 0
for i in range(N + 1):
    sum = sum + i
print(sum)

Submission status: Accepted

Solution code:
n=int(input());print(-~n*n//2)

Submission status: Accepted

Solution code:
N=int(input())
count=0
for i in range(1,N+1):
	count+=i

print(count)

Submission status: Accepted

Solution code:
N=int(input())


print(int(((N+1)*N)/2))

Submission status: Accepted

Solution code:
total=0
for i in range(int(input())+1):
    total+=i
print(total)

Submission status: Accepted

Solution code:
n = int(input())
ans = 0
for i in range(1, n+1):
    ans = ans + i
print(ans)

Submission status: Accepted

Solution code:
n = int(input())
 
print(int(n*(n+1)/2))

Submission status: Accepted

Solution code:
n=int(input())
print(sum([i for i in range(1,n+1)]))

Submission status: Accepted

Solution code:
N = int(input())
cnt = 0
for i in range(N):
    cnt += (i + 1)
    
print(cnt)

Submission status: Accepted

Solution code:
def resolve():
    N = int(input())
    print(int((1+N) * N * (1/2)))

resolve()

Submission status: Accepted

Solution code:
n=int(input())
print(n*-~n//2)

Submission status: Accepted

Solution code:
n = int(input())
sum = 0
for i in range(1, n+1):
    sum += i
print(sum)

Submission status: Accepted

Solution code:
N = int(input())

def ame(N):
    total = 0
    for i in range(1, N + 1):
        total += i
    return total
    
print(ame(N))

Submission status: Accepted

Solution code:
n=int(input())

ans=sum([i for i in range(n+1)])

print(ans)

Submission status: Accepted

Solution code:
N = int(input())
ans = sum([i for i in range(N+1)])
print(ans)

Submission status: Accepted

Solution code:
N = int(input())
print((1+N)*N//2)

Submission status: Accepted

Solution code:
k=input()
a=int(k)
b=1
c=0
for j in range(1,a+1):
  c+=j
print(c)

Submission status: Accepted

Solution code:
N = int(input())

print(sum(range(1, N+1)))

Submission status: Accepted

Solution code:
N = int(input())
counter = 0
for val in range(N+1):
    counter = counter + int(val)
print(counter)

Submission status: Accepted

Solution code:
# 入力 N
a = int(input())
# キャンディーの個数の合計
sum = a * (a+1) / 2
print(int(sum))

Submission status: Accepted

Solution code:
n = int(input())
count = 0
for i in range(1,n+1):
  count += i
print(count)

Submission status: Accepted

Solution code:
a = int(input())
print(sum(range(1,a+1)))

Submission status: Accepted

Solution code:
n = int(input())
c = 0
for i in range(n+1):
    c += i
print(c)

Submission status: Accepted

Solution code:
N=int(input())
p=0
for i in range(1,N+1):
  p=p+i
print(p)

Submission status: Accepted

Solution code:
a = int(input())
answer = 0
for i in range(a+1):
  answer += i
  
print(answer)

Submission status: Accepted

Solution code:
N = int(input())

t = 0
for i in range(1, N+1):
    t = t + i
print(t)

Submission status: Accepted

Solution code:
b = int(input())
c = 0
for i in range(b+1):
    c += i
print(c)

Submission status: Accepted

Solution code:
n = int(input())
c = 0
for i in range(1,n+1):
  c += i
print(c)

Submission status: Accepted

Solution code:
"""
author : halo2halo
date : 4, Feb, 2020
"""

import sys
import itertools

import numpy as np

read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines

N = int(readline())

print((N+1)*N//2)

Submission status: Accepted

Solution code:
N = int(input())
sum = 0
for i in range(1,N+1):
	sum += i
print(sum)

Submission status: Accepted

Solution code:
n = int(input())

candy = 0
for index in range(n):
    candy += index + 1
print(str(candy))

Submission status: Accepted

Solution code:
n = int(input())
ret = 0
for i in range(n+1):
    ret += i
print(ret)

Submission status: Accepted

Solution code:
print(sum([i for i in range((int(input()))+1)]))

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
# -*- coding: utf-8 -*-


def main():
    N = int(input())
    result = 0
    for i in range(N + 1):
        result += i
    print(result)


if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
# AtCoder Beginner Contest 043
# A - キャンディーとN人の子供イージー / Children and Candies (ABC Edit)
N = int(input())
C = 0
for i in range(N):
    C = C + (i+1)
print(C)

Submission status: Accepted

Solution code:
a = int(input())
ans = 0
 
for i in range(a):
  i += 1
  ans = ans + i
  
print(ans)

Submission status: Accepted

Solution code:
print(sum([i for i in range(1, int(input()) + 1)]))

Submission status: Accepted

Solution code:
N = int(input())

sum = 0

for i in range(N):
    sum += i + 1

print(sum)

Submission status: Accepted

Solution code:
children = int(input())

candy = 0
for c in range(children):
    candy += (c+1)
  
print(candy)

Submission status: Accepted

Solution code:
n = int(input())
f = 0
for i in range(n+1):
    f+=i
print(f)

Submission status: Accepted

Solution code:
N = int(input())

ans = N * (N + 1) // 2

print(ans)

Submission status: Accepted

Solution code:
N = int(input())

print(int((N+1)*N/2))

Submission status: Accepted

Solution code:
N = int(input())
print(int((1 / 2) * N * (2 + (N - 1))))

Submission status: Accepted

Solution code:
n = int(input())

s = 0

for i in range(1, n+1):
  s += i

print(s)

Submission status: Accepted

Solution code:
n = int(input())
a = 0

for i in range(n):
    a += i+1
print(a)

Submission status: Accepted

Solution code:
N = int(input())
s = 0
for i in range(1, N+1):
	s += i
print(s)

Submission status: Accepted

Solution code:
n = int(input())
j = 0
for i in range(n+1):
  j = j + i
  
print(j)

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
N=int(input())
s=0
for i in range(N+1):
    s += i
print(s)

Submission status: Accepted

Solution code:
import sys
import numpy as np

# N 子供の数入力
n = int(input())

child = np.arange(1, n + 1)

print(child.sum())

Submission status: Accepted

Solution code:
N = int(input())
a=0
for i in range(N+1):
    a = a + i
print(a)

Submission status: Accepted

Solution code:
def main():
    from sys import stdin, setrecursionlimit
    #setrecursionlimit(10**9)
    n = int(stdin.readline()[:-1])   
    #r = stdin.readline()[:-1]
    #r = [stdin.readline() for i in range(n)]
    #t = [int(stdin.readline()) for i in range(n)]
    #n = int(r)
    #a = r.split()
    #a,b,c = r.split()
    #a = list(map(int, r.split()))
    #a,b,c,d = map(int, r.split())
    #a = [int(s[i]) for i in range(1, n+1)]
    #a = [list(map(int, r.split())) for i in range(1,n+1)]
    #res = 0
    print((1+n)*n//2)

if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
n=int(input())
x=0
for i in range(1,n+1):
  x += i
print(x)

Submission status: Accepted

Solution code:
a=int(input())
print(int((1+a)*a/2))

Submission status: Accepted

Solution code:
def calc_sum_of_candies(sum_of_children):
    sum_of_candies = 0
    for i in range(sum_of_children+1):
        sum_of_candies = sum_of_candies + i

    return sum_of_candies

if __name__=='__main__':
    sum_of_children = int(input())
    print(calc_sum_of_candies(sum_of_children))

Submission status: Accepted

Solution code:
N = int(input())

print(sum([i for i in range(1,N + 1)]))

Submission status: Accepted

Solution code:
N = int(input())
li = []
for i in range (N):
  li.append (1+i)

print(sum(li))

Submission status: Accepted

Solution code:
N = int(input())

count = 0
for i in range(N):
  count += i + 1

print(count)

Submission status: Accepted

Solution code:
count = int(input())
answer = 0
for i in range(1, count + 1):
    answer = answer + i
print(answer)

Submission status: Accepted

Solution code:
if __name__ == "__main__":
    N = int(input())
    print(sum(range(1, N+1)))

Submission status: Accepted

Solution code:
N = int(input())

print(sum(list(range(1,N+1))))

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline
n=int(input())
ans=0
for i in range(1,n+1):
    ans+=i
print(ans)

Submission status: Accepted

Solution code:
# -*-coding: utf-8 -*-

#整数の入力
N = int(input())

sum = 0

for i in range(N):
    i = i + 1
    sum = sum + i

print(sum)

Submission status: Accepted

Solution code:
N=int(input())
s=N*(N+1)/2
print(int(s))

Submission status: Accepted

Solution code:
N = int(input())

S = N*(N+1)//2

print(S)

Submission status: Accepted

Solution code:
N = int(input())
print(int(0.5 * (N ** 2 + N)))

Submission status: Accepted

Solution code:
n = int(input())
print(n*(n+1) // 2)

Submission status: Accepted

Solution code:
import sys
 
N = int(input())
sum = 0
for i in range(N + 1):
  sum += i
print(str(sum))

Submission status: Accepted

Solution code:
n=int(input())
ans=0
for i in range(n):
    ans+=(i+1)
print(ans)

Submission status: Accepted

Solution code:
N = int(input())

ans = 0
for i in range(1, N+1):
  ans += i

print(ans)

Submission status: Accepted

Solution code:
N = int(input(), 10)
print(sum([n for n in range(1, N+1)]))

Submission status: Accepted

Solution code:
# coding: utf-8
N=int(input())
ans=0
for i in range(1,N+1):
    ans+=i
print(ans)

Submission status: Accepted

Solution code:
# coding: utf-8
n = int(input())
print((n*(n+1))//2)

Submission status: Accepted

Solution code:
import sys
import math
def i():return int(sys.stdin.readline().replace("\n",""))
def i2():return map(int,sys.stdin.readline().replace("\n","").split())
def s():return str(sys.stdin.readline().replace("\n",""))
def l():return list(sys.stdin.readline().replace("\n",""))
def intl():return [int(k) for k in sys.stdin.readline().replace("\n","").split()]
def lx():return list(map(lambda x:int(x)*-1,sys.stdin.readline().replace("\n","").split()))
def t():return tuple(map(int,sys.stdin.readline().replace("\n","").split()))

if __name__ == "__main__":pass

n = i()
a = [i for i in range(1,n+1)]
print(sum(a))

Submission status: Accepted

Solution code:
N=int(input())
ans = 0
for i in range(1,N+1):
    ans += i
print(ans)

Submission status: Accepted

Solution code:
n = int(input())

ans = 0
for i in range(1, n + 1):
    ans += i

print(ans)

Submission status: Accepted

Solution code:
n = int(input())
ans = sum(list(range(1,n+1)))
print(ans)

Submission status: Accepted

Solution code:
s = input()
total = 0
for i in range(int(s)+1):
    total += i
print(total)

Submission status: Accepted

Solution code:
n = int(input())
total = 0
for i in range(n+1):
    total += i
print(total)

Submission status: Accepted

Solution code:
n = int(input())
t = 0

for i in range(n+1):
	t += i

print(t)

Submission status: Accepted

Solution code:
def factorial(n):
    if n == 1:
        return 1
    else:
        return n + factorial(n-1)

a = int(input())
print(factorial(a))

Submission status: Accepted

Solution code:
N = int(input())
if N % 2 == 0:
  r = (N + 1) * N / 2
else:
  r = N * (N - 1) / 2 + N

print(int(r))

Submission status: Accepted

Solution code:
n = int(input())
sum=0
for i in range(1,n+1):
    sum+=i
print(sum)

Submission status: Accepted

Solution code:
subin = int(input())
res = int((1+subin) * subin / 2)
print(res)

Submission status: Accepted

Solution code:
n = int(input())
ans = n * (n+1) / 2
print(int(ans))

Submission status: Accepted

Solution code:
n = int(input())
print((n*(n+1)) // 2)

Submission status: Accepted

Solution code:
n = int(input())
sum = 0

for i in range(1, n + 1):
    sum += i
    
print(sum)

Submission status: Accepted

Solution code:
n = int(input())

result = 0
for i in range(1,n+1):
  result += i

print(result)

Submission status: Accepted

Solution code:
a = int(input())
print(a*(a+1)//2)

Submission status: Accepted

Solution code:
n = int(input())
ans = sum(list(range(n, 0, -1)))
print(ans)

Submission status: Accepted

Solution code:
print(sum([n for n in range(1, int(input())+1)]))

Submission status: Accepted

Solution code:
N = int(input())
sum = 0
for i in range(N):
    sum+=(i+1)
print(sum)

Submission status: Accepted

Solution code:
n=int(input())
sum=0
for i in range(n):
  sum+=(i+1)
print(sum)

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline
N = int(input())
print(((1 + N) * N) // 2)

Submission status: Accepted

Solution code:
enji = int(input())
goukei = 0
for num in range(1,enji):
    goukei = goukei + num
goukei = goukei + enji
print(goukei)

Submission status: Accepted

Solution code:
N = int(input())
ans = 0
for i in range(1, N+1):
	ans += i
print(ans)

Submission status: Accepted

Solution code:
N = int(input())
r=0
for i in range(N):
  r +=i+1
print(r)

Submission status: Accepted

Solution code:
children = int(input())
total = 0
for i in range(children):
  i += 1
  total += i
print(total)

Submission status: Accepted

Solution code:
n = int(input())

num = 0
for i in range(n):
  num = num + i + 1
print(num)

Submission status: Accepted

Solution code:
n=int(input())
a=0
for i in range(n+1):
    a+=i
print(a)

Submission status: Accepted

Solution code:
n = int(input())

c = 0
for i in range(1, n+1):
   c += i

print(c)

Submission status: Accepted

Solution code:
n = int(input())
res = 0
for i in range(n+1):
    res += i
print(res)

Submission status: Accepted

Solution code:
N = int(input())
print(int(N * (1 + N) / 2))

Submission status: Accepted

Solution code:
n = int(input())
ans=0
for i in range(n):
    ans+=1+i
print(ans)

Submission status: Accepted

Solution code:
n = int(input())

ans = 0

for i in range(n+1):
   ans += i
print(ans)

Submission status: Accepted

Solution code:
N = int(input())
ans = sum([i for i in range(1, N+1)])
print(ans)

Submission status: Accepted

Solution code:
n = int(input())
ans = 0
for x in range(n+1):
  ans += x
print(ans)

Submission status: Accepted

Solution code:
def sigma(n: int) -> int:
    sum = 0
    if n != 1:
        sum += n
        sum += sigma(n-1)
    else:
        sum += n
        return sum

    return sum

n = int(input())
total = sigma(n)
print(total)

Submission status: Accepted

Solution code:
import math
import fractions

n = int(input())
print(n * (n + 1) // 2)

Submission status: Accepted

Solution code:
N = int(input())
ans = 0
for i in range(1,N+1):
	ans += i
print(ans)

Submission status: Accepted

Solution code:
def gauss(n):
    ans = int (n * (n + 1) / 2)
    return(ans) 

N = int(input())

print(gauss(N))

Submission status: Accepted

Solution code:
n = int(input())
print(n*(n+1)//2)

Submission status: Accepted

Solution code:
n = int(input())

print(int(n*(1+n)/2))

Submission status: Accepted

Solution code:
a = int(input())
s = 0
for i in range(a+1):
  s += i
print(s)

Submission status: Accepted

Solution code:
n = int(input())

candy = 0

for i in range(1,n+1):
    candy += i

print(candy)

Submission status: Accepted

Solution code:
n = int(input())
sum=0
for i in range(1,n+1):
	sum+=i
print(sum)

Submission status: Accepted

Solution code:
N=int(input())
print(int(N * (N + 1) / 2))

Submission status: Accepted

Solution code:
N = int(input())
a = N*(N+1)//2
print(a)

Submission status: Accepted

Solution code:
# # -*- coding: utf-8 -*-
N = int(input())
print((N+1) * N // 2)

Submission status: Accepted

Solution code:
n = int(input())
print(int(n/2*(n+1)))

Submission status: Accepted

Solution code:
n = int(input())

count = 0
for i in range(1, n+1):
    count += i

print(count)

Submission status: Accepted

Solution code:
n = int(input())
r = n*(n+1)//2
print(r)

Submission status: Accepted

Solution code:
n=int(input())
counter=0
for i in range(n+1):
  counter+=i

print(counter)

Submission status: Accepted

Solution code:
# coding: utf-8
import sys


def main(argv=sys.argv):
  
  n = int(input())
  
  candy_count = 0

  if n == 1:
    candy_count = 1
  else:
    candy_count = (1 + n) * n // 2
    
  print(candy_count)
  
  return 0


if __name__ == '__main__':
  sys.exit(main())

Submission status: Accepted

Solution code:
# coding: utf-8
import sys

def main(argv=sys.argv):
  
  n = int(input())
  total = 0
  
  for i in range(n+1):
    total += i
  
  print(total)
  
  return 0

if __name__ == '__main__':
  sys.exit(main())

Submission status: Accepted

Solution code:
n = int(input())
print(int((n + 1) * n / 2))

Submission status: Accepted

Solution code:
import math
import queue
import bisect
import heapq
import time
import itertools

mod = int(1e9+7)

def swap(a,b):
    return (b,a)

def gcd(a,b): #最大公約数
    if (a<b):
        a,b = swap(a,b)
    if (b==0):
        return a
    else:
        return gcd(b,a%b)

def divisors(a): # 約数列挙
    divisors = []
    for i in range(1,int(a**0.5)+1):
        if a%i==0:
            divisors.append(i)
            if i!=a//i:
                divisors.append(a//i)
    return divisors

def is_prime(a): #素数判定
    if a<2:
        return False
    elif a==2:
        return True
    elif a%2==0:
        return False
    sqrt_num = int(a**0.5)
    for i in range(3,sqrt_num+1,2):
        if a%i==0:
            return False
    return True

def prime_num(a): #素数列挙
    pn = [2]
    for i in range(3,int(a**0.5),2):
        prime = True
        for j in pn:
            if i%j==0:
                prime = False
                break
        if prime:
            pn.append(i)
    return pn

def main():
    n = int(input())
    ans = 0
    for i in range(n):
        ans += i + 1
    print(ans)
    return

if __name__=='__main__':
    main()

Submission status: Accepted

Solution code:
ans = 0
for i in range(1,int(input())+1):
  ans += i
print(ans)

Submission status: Accepted

Solution code:
n = int(input())

print(int((n+1) * n/2))

Submission status: Accepted

Solution code:
n = int(input())

print((n + 1)*n//2)

Submission status: Accepted

Solution code:
# AtCoder Beginner Contest 043 - A
# -*- encoding: UTF-8 -*-
n = int(input())

m = int((n+1) * n / 2)

print(m)

Submission status: Accepted

Solution code:
A = int(input())
sum = 0
for i in range(1,A+1):
	sum += i
print(str(sum))

Submission status: Accepted

Solution code:
#coding:utf-8
 
value = int(input())
 
gokei = 0
 
for i in range(value):
    gokei += i + 1
    
print(gokei)

Submission status: Accepted

Solution code:
# ABC043 A

n = int(input())
ans = 0

for i in range(1,n+1):
    ans += i

print(ans)

Submission status: Accepted

Solution code:
N = list(range(1,int(input())+1))

print(sum(N))

Submission status: Accepted

Solution code:
a = int( input() )

sol = a * ( a + 1 ) // 2 

print( sol )

Submission status: Accepted

Solution code:
N = int(input())
x = 0
for i in range(1,N+1):
    x = x + i
print(x)

Submission status: Accepted

Solution code:

N = int(input())

ans = 0
for i in range(N+1):
    ans += i

print(ans)

Submission status: Accepted

Solution code:
子供の数=int(input())
答え=0
for 飴の数 in range(1,子供の数+1):
  答え+=飴の数
print(答え)

Submission status: Accepted

Solution code:
n = int(input())
sum = 0
for i in range(1,n+1):
  sum +=i
print(sum)

Submission status: Accepted

Solution code:
n=int(input())
print((1+n)*n//2)

Submission status: Accepted

Solution code:
n = int(input())
i = 1
sum = 0
for i in range(1,n + 1):
  sum += i
print(sum)

Submission status: Accepted

Solution code:
n=int(input())
sum_n=0
for i in range(n+1):
  sum_n+=i
print(sum_n)

Submission status: Accepted

Solution code:
N = int(input())

n = 0

for i in range(N):
  n += i+1
print(n)

Submission status: Accepted

Solution code:
n = int(input())
j = 1
k = 0
for i in range(n):
  k += j
  j += 1
print(k)

Submission status: Accepted

Solution code:
import sys

n = int(sys.stdin.readline().rstrip())

def main():
    ans = (1 + n) * n // 2
    return ans 

if __name__ == '__main__':
    ans = main()
    print(ans)

Submission status: Accepted

Solution code:
n=int(input())
k=n*(n+1)/2
print(int(k))

Submission status: Accepted

Solution code:
a = input()
a=int(a)
ans=0
for i in range(1,a+1):
  ans+=i
print(ans)

Submission status: Accepted

Solution code:
n = int(input())

ans = 0
for i in range(1, n + 1):
    ans += i

print(ans)

Submission status: Accepted

Solution code:
n = int(input())

print(int(n * (n + 1) / 2))

Submission status: Accepted

Solution code:
a=int(input())
b=0
for i in range(a+1):
    b=b+i
print(b)

Submission status: Accepted

Solution code:
n = int(input())
a = 0
b = 0
while a <= n:
	b = b + a
	a += 1
print(b)

Submission status: Accepted

Solution code:
N = int(input())

result =0
print(sum([result + i for i in range(1, N+1)]))

Submission status: Accepted

Solution code:
a = int(input())
print('{:.0f}'.format((a+1)*a/2))

Submission status: Accepted

Solution code:
N = int(input())

ans = 0

for i in range(1,N+1):
    ans += i
print(ans)

Submission status: Accepted

Solution code:
N = int(input())
candy = 0
for i in range(N + 1):
    candy += i

print(candy)

Submission status: Accepted

Solution code:
n=int(input())
s=0
for i in range(1,n+1):
    s+=i
print(s)

Submission status: Accepted

Solution code:
n = int(input())
c = 0

for i in range(n + 1):
    c += i
print(c)

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
# -*- coding: utf-8 -*-

N = int(input())

R = 0
for i in range(N):
    R += i + 1

print(R)

Submission status: Accepted

Solution code:
import numpy
n = int(input())

hairetsu = numpy.arange(1, n+1, 1)

print(sum(hairetsu))

Submission status: Accepted

Solution code:
N = int(input())
sum = 0

for i in range(N + 1):
    sum += i

print(sum)

Submission status: Accepted

Solution code:
a=int(input())
ans=0
for i in range(1,a+1):
  ans+=i
print(ans)

Submission status: Accepted

Solution code:
a = int(input())
b=0
for i in range(0,a+1):
  b += i
print(b)

Submission status: Accepted

Solution code:
n = int(input())
print(n*(n + 1)//2)

Submission status: Accepted

Solution code:
def a(s):
  if s == 1:
    return s
  return s + a(s-1) 

print(a(int(input())))

Submission status: Accepted

Solution code:
N = int(input())

print(N * (N + 1) // 2)

Submission status: Accepted

Solution code:
n = int(input())
print(n*(n + 1) // 2)

Submission status: Accepted

Solution code:
n = int(input())
ans = 0

for i in range(n + 1):
    ans += i

print(ans)

Submission status: Accepted

Solution code:
x=int(input())
print(x*(x+1)//2)

Submission status: Accepted

Solution code:
num = int(input())
candy_num = 0

for i in range(1,num+1):
  candy_num += i

print(candy_num)

Submission status: Accepted

Solution code:
si = lambda: input()
ni = lambda: int(input())
nm = lambda: map(int, input().split())
nl = lambda: list(map(int, input().split()))
n = ni()
print(int((n*(n+1))/2))

Submission status: Accepted

Solution code:
from sys import stdin

n = int(stdin.readline().rstrip())

print(n*(n+1)//2)

Submission status: Accepted

Solution code:
N=int(input())
ans=N*(N+1)//2
print(ans)

Submission status: Accepted

Solution code:
n = int(input())

sum = 0
for i in range(n):
    sum += i+1

print(sum)

Submission status: Accepted

Solution code:
#Nは子供の人数
N=int(input())
S=0
for i in range(1,N+1):
    S=S+i
print(S)

Submission status: Accepted

Solution code:
N = int(input())

print(sum(range(N+1)))

Submission status: Accepted

Solution code:
n = int(input())
if n % 2 == 0:
  print(int((n+1)*n/2))
else:
  print(int((n+1)*(n-1)/2+(n+1)/2))

Submission status: Accepted

Solution code:
n = int(input())
print(int((n+1)*n/2))

Submission status: Accepted

Solution code:
x=int(input())
print(sum(range(x+1)))

Submission status: Accepted

Solution code:
n = int(input())

number=0
for i in range(1,n+1):
    number +=i

print(number)

Submission status: Accepted

Solution code:
S=int(input())
ans=0
for i in range(1,S+1):
  ans+=i
print(ans)

Submission status: Accepted

Solution code:
a = int(input())
print(int((a * (a + 1)) / 2))

Submission status: Accepted

Solution code:
N = int(raw_input())
print sum(range(N + 1))

Submission status: Accepted

Solution code:
N = int(input())

candy = 0
for num in range(N+1):
    candy += num

print(candy)

Submission status: Accepted

Solution code:
n=int(input())
r=0
for i in range(n):
  r=r+i+1

print(r)

Submission status: Accepted

Solution code:
N = int(input())
print(N * (N + 1) // 2)

Submission status: Accepted

Solution code:
n = int(input())
print(sum([i for i in range(1, n+1)]))

Submission status: Accepted

Solution code:
N=int(input())
print((1+N)*N//2)

Submission status: Accepted

Solution code:
n = int(input())
count = 0
for i in range(n):
    count += i+1
print(count)

Submission status: Accepted

Solution code:
n = int(input())
print((n * (n+1)) // 2)

Submission status: Accepted

Solution code:
import math

n = int(input())
print(int(n * (n + 1) / 2))

Submission status: Accepted

Solution code:
n = int(input())
print(((n)*(n+1))//2)

Submission status: Accepted

Solution code:
N = int(input())
camdy_for_pair =  (1 + N)
num_of_pairs, amari = divmod((N),2)

if amari == 0:
    nesseary_candy = num_of_pairs * camdy_for_pair
else :
    nesseary_candy = num_of_pairs * camdy_for_pair + num_of_pairs + 1
    
print(nesseary_candy)

Submission status: Accepted

Solution code:
N = int(input())
ans = sum(i for i in range(1,N+1))
print(ans)

Submission status: Accepted

Solution code:
n = int(raw_input())
out = 0

for i in range(1, n+1):
  out += i
print(out)

Submission status: Accepted

Solution code:
n = int(input())

a = 0
for n in range(1, n+1):
    a = n + a
print(a)

Submission status: Accepted

Solution code:
n = int(input())
print(n*(n+1) //2)

Submission status: Accepted

Solution code:
N = int(input())

Answer = N * (N + 1) // 2
print(Answer)

Submission status: Accepted

Solution code:
N = int(input())
t = 0

for i in range(N):
	t += i + 1 

print(t)

Submission status: Accepted

Solution code:
n = int(input())
s = n*(n+1)/2
print (int(s))

Submission status: Accepted

Solution code:
##### 解けた #####

N=int(input())

print(int((N+1)*N/2))

Submission status: Accepted

Solution code:
n = int(input())
ans = 0
for i in range(n):
    ans += n
    n -= 1
print(ans)

Submission status: Accepted

Solution code:
number=int(input())

print(int(number*(number+1)/2))

Submission status: Accepted

Solution code:
#ABC043_A

N = int(input())

sum = 0

for i in range(N+1):
	sum += i

print(sum)

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
import sys, math, itertools, heapq, collections, bisect, fractions
input = lambda: sys.stdin.buffer.readline().rstrip().decode('utf-8')
sys.setrecursionlimit(10**8)
inf = float('inf')
ans = count = 0

n=int(input())
print(sum(range(n+1)))