#include <bits/stdc++.h>
using namespace std;
int main(){
	int a,b=0;
	cin>>a;
	int e=0;
	while(a>=1){
		e=a*a;
		b=e+b;
		a--;	
	}
	cout<<b;
	
}	
/**************************************************************
	Problem: 1054
	User: toughuatao1
	Language: C++
	Result: Accepted
	Time:14 ms
	Memory:2072 kb
****************************************************************/