#include <bits/stdc++.h>
using namespace std;
int main() {
  long long n;
  cin >> n;
  cout << n * (n - 1) * (n - 2) * (n - 3) * (n - 4) / (5 * 4 * 3 * 2) * n *
              (n - 1) * (n - 2) * (n - 3) * (n - 4)
       << endl;
  return 0;
}
