#include <stdio.h> int main() { int day,coin=1,sum=0,n,past=0; scanf("%d",&n); for(day=1;day<=n;day++) { past++; sum+=coin; if(past==coin) { past=0; coin++; } } printf("%d",sum); return 0; }