n = int(eval(input()))



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



print(answer)
n = int(eval(input()))

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

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

-answer = int((n + 1) * n / 2) -print(answer) +print((int((n + 1) * n / 2)))