1
0
mirror of https://github.com/Kiritow/OJ-Problems-Source.git synced 2024-03-22 13:11:29 +08:00

12 lines
174 B
C++
Raw Normal View History

2016-08-13 17:16:08 +08:00
#include <iostream>
using namespace std;
int n;
int main()
{
while(scanf("%d",&n) != EOF)
{
cout<<(n*n*n + 5*n + 6)/6<<endl;
}
return 0;
}