#include <bits/stdc++.h>
using namespace std;
long long gcd(long long n, long long m) {
  if (m == 0)
    return n;
  else
    return gcd(m, n % m);
}
int longestsub(string x, string y, int n, int m) {
  int lcs[n + 1][m + 1];
  int result = 0;
  for (int i = 0; i < n + 1; i++) {
    for (int j = 0; j < m + 1; j++) {
      if (i == 0 || j == 0) {
        lcs[i][j] = 0;
      } else if (x[i - 1] == y[j - 1]) {
        lcs[i][j] = 1 + lcs[i - 1][j - 1];
        result = max(result, lcs[i][j]);
      } else
        lcs[i][j] = 0;
    }
  }
  return result;
}
long long fast_pow(long long a, long long p) {
  long long res = 1;
  while (p) {
    if (p % 2 == 0) {
      a = a * 1ll * a % 1000000007;
      p /= 2;
    } else {
      res = res * 1ll * a % 1000000007;
      p--;
    }
  }
  return res;
}
long long fact(long long n) {
  long long res = 1;
  for (int i = 1; i <= n; i++) {
    res = res * 1ll * i % 1000000007;
  }
  return res;
}
long long C(long long n, long long k) {
  return fact(n) * 1ll * fast_pow(fact(k), 1000000007 - 2) % 1000000007 * 1ll *
         fast_pow(fact(n - k), 1000000007 - 2) % 1000000007;
}
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(NULL);
  cout.tie(NULL);
  ;
  int t = 1;
  while (t--) {
    int n;
    cin >> n;
    long long ans = 2 * 3;
    for (int i = 3; i < n; i++) {
      ans += i * (i + 1);
    }
    cout << ans << '\n';
  }
}
