print(sum([ x for x in range(int(input())) ]))