n[];main(s){while(gets(n)){s=atoi(n);printf("%d\n",s*(s+1)*(2*s+1)/6);}}