#include <bits/stdc++.h>
using namespace std;
template <typename T>
T read() {
  T res;
  std::cin >> res;
  return res;
}
template <typename T>
void print(const T& t) {
  std::cout << t;
}
template <>
int read<int>() {
  int res;
  scanf("%d", &res);
  return res;
}
template <>
void print<int>(const int& t) {
  printf("%d", t);
};
template <>
unsigned int read<unsigned int>() {
  unsigned int res;
  scanf("%u", &res);
  return res;
}
template <>
void print<unsigned int>(const unsigned int& t) {
  printf("%u", t);
};
template <>
int64_t read<int64_t>() {
  int64_t res;
  scanf("%lld", &res);
  return res;
}
template <>
void print<int64_t>(const int64_t& t) {
  printf("%lld", t);
};
template <>
float read<float>() {
  float res;
  scanf("%f", &res);
  return res;
}
template <>
void print<float>(const float& t) {
  printf("%f", t);
};
template <>
double read<double>() {
  double res;
  scanf("%lf", &res);
  return res;
}
template <>
void print<double>(const double& t) {
  printf("%lf", t);
};
template <>
char read<char>() {
  char res;
  scanf("%c", &res);
  return res;
}
template <>
void print<char>(const char& t) {
  printf("%c", t);
};
template <typename T>
class Range {
 public:
  Range(T start, T end) : start_(std::min(start, end)), end_(end) {}
  class Iterator {
   public:
    Iterator(T pos) : pos_(pos) {}
    Iterator& operator++() {
      ++pos_;
      return *this;
    }
    const T& operator*() const { return pos_; }
    bool operator==(const Iterator& other) const { return pos_ == other.pos_; }
    bool operator!=(const Iterator& other) const { return !(*this == other); }

   private:
    T pos_;
  };
  Iterator begin() const { return {start_}; }
  Iterator end() const { return {end_}; }
  const T start_, end_;
};
template <typename T>
Range<T> range(T start, T end) {
  return {start, end};
}
template <typename T>
Range<T> range(T end) {
  return {0, end};
}
template <typename T>
T binomialCoefficient(T one, int64_t n, int64_t k) {
  if (n < 0) return T(0);
  if (k >= n || k <= 0) return one;
  k = std::min(k, n - k);
  auto res = one;
  for (int64_t i = k - 1; i >= 0; --i) res = (res * (n - i)) / (k - i);
  return res;
}
class Solver630F {
 public:
  void run();
};
void Solver630F::run() {
  int64_t n;
  cin >> n;
  int64_t one = 1;
  cout << binomialCoefficient(one, n, 5) + binomialCoefficient(one, n, 6) +
              binomialCoefficient(one, n, 7);
}
using CurrentSolver = Solver630F;
int main() {
  CurrentSolver().run();
  return 0;
}

### Prompt

Your challenge is to write a cpp solution to the following problem:

One company of IT City decided to create a group of innovative developments consisting from 5 to 7 people and hire new employees for it. After placing an advertisment the company received n resumes. Now the HR department has to evaluate each possible group composition and select one of them. Your task is to count the number of variants of group composition to evaluate.

Input

The only line of the input contains one integer n (7 ≤ n ≤ 777) — the number of potential employees that sent resumes.

Output

Output one integer — the number of different variants of group composition.

Examples

Input

7


Output

29

### Response

```cpp
#include <bits/stdc++.h>
using namespace std;
template <typename T>
T read() {
  T res;
  std::cin >> res;
  return res;
}
template <typename T>
void print(const T& t) {
  std::cout << t;
}
template <>
int read<int>() {
  int res;
  scanf("%d", &res);
  return res;
}
template <>
void print<int>(const int& t) {
  printf("%d", t);
};
template <>
unsigned int read<unsigned int>() {
  unsigned int res;
  scanf("%u", &res);
  return res;
}
template <>
void print<unsigned int>(const unsigned int& t) {
  printf("%u", t);
};
template <>
int64_t read<int64_t>() {
  int64_t res;
  scanf("%lld", &res);
  return res;
}
template <>
void print<int64_t>(const int64_t& t) {
  printf("%lld", t);
};
template <>
float read<float>() {
  float res;
  scanf("%f", &res);
  return res;
}
template <>
void print<float>(const float& t) {
  printf("%f", t);
};
template <>
double read<double>() {
  double res;
  scanf("%lf", &res);
  return res;
}
template <>
void print<double>(const double& t) {
  printf("%lf", t);
};
template <>
char read<char>() {
  char res;
  scanf("%c", &res);
  return res;
}
template <>
void print<char>(const char& t) {
  printf("%c", t);
};
template <typename T>
class Range {
 public:
  Range(T start, T end) : start_(std::min(start, end)), end_(end) {}
  class Iterator {
   public:
    Iterator(T pos) : pos_(pos) {}
    Iterator& operator++() {
      ++pos_;
      return *this;
    }
    const T& operator*() const { return pos_; }
    bool operator==(const Iterator& other) const { return pos_ == other.pos_; }
    bool operator!=(const Iterator& other) const { return !(*this == other); }

   private:
    T pos_;
  };
  Iterator begin() const { return {start_}; }
  Iterator end() const { return {end_}; }
  const T start_, end_;
};
template <typename T>
Range<T> range(T start, T end) {
  return {start, end};
}
template <typename T>
Range<T> range(T end) {
  return {0, end};
}
template <typename T>
T binomialCoefficient(T one, int64_t n, int64_t k) {
  if (n < 0) return T(0);
  if (k >= n || k <= 0) return one;
  k = std::min(k, n - k);
  auto res = one;
  for (int64_t i = k - 1; i >= 0; --i) res = (res * (n - i)) / (k - i);
  return res;
}
class Solver630F {
 public:
  void run();
};
void Solver630F::run() {
  int64_t n;
  cin >> n;
  int64_t one = 1;
  cout << binomialCoefficient(one, n, 5) + binomialCoefficient(one, n, 6) +
              binomialCoefficient(one, n, 7);
}
using CurrentSolver = Solver630F;
int main() {
  CurrentSolver().run();
  return 0;
}

```