#include using namespace std; long sumOfGroup(long int k) { // Return the sum of the elements of the k'th group. long int n,sum,i; n=k*(k-1)+1; sum=0; while(k--) { //n=n+2; sum=sum+n; n+=2; } return sum; } int main() { long int k; cin >> k; long answer = sumOfGroup(k); cout << answer << endl; return 0; }