#include #include #include #include #include #include #include long long sumOfGroup(long long k) { // Return the sum of the elements of the k'th group. long long x=0, t = (k-1)*(k)+1; while(k--) { x+=t; t += 2; } return x; } int main() { long long k; scanf("%lld", &k); long long answer = sumOfGroup(k); printf("%lld\n", answer); return 0; }