#include<bits/stdc++.h>
using namespace std;
int main()
{
    ios_base::sync_with_stdio(false);
    cin.tie(NULL);

    long long n;
    cin >> n;
   long long ans = (n - 1) * n * (n + 1) / 3;

    cout << ans << "\n";

    return 0;
}