"""
1.5 编程基础之循环控制 45 金币
http://noi.openjudge.cn/ch0105/45/
http://ybt.ssoier.cn:8088/problem_show.php?pid=1969
P2669 [NOIP2015 普及组] 金币
https://www.luogu.com.cn/problem/P2669
"""
n=1
coin=0
k=int( input() )
for i in range(1,k+1):
coin+=n
if i==( n*(n+1)//2 ):
n+=1
print( coin )
P2440 木材加工
https://blog.csdn.net/dllglvzhenfeng/article/details/122741515
P2415 集合求和(python3实现)
https://blog.csdn.net/dllglvzhenfeng/article/details/122808195
P2550 [AHOI2001]彩票摇奖(python3实现)
https://blog.csdn.net/dllglvzhenfeng/article/details/122784858
P2651 添加括号III(python3实现)
https://blog.csdn.net/dllglvzhenfeng/article/details/122774379
P2660 zzc 种田( python3实现)
https://blog.csdn.net/dllglvzhenfeng/article/details/122774803