题解 | #等差数列#
等差数列
http://www.nowcoder.com/practice/f792cb014ed0474fb8f53389e7d9c07f
#include <bits/stdc++.h>
using namespace std;
int main()
{
int n;
while ( cin >> n )
{
cout << 2*n+n*(n-1)*3/2;
}
return 0;
}