n = int(input()) s = 0 for i in n: s = s + n n = n - 1 if n == 0: break print(s)