#include <bits/stdc++.h>
using namespace std;
int n;
int bfs(int cou, int now);
int main() {
  while (cin >> n) {
    cout << bfs(0, 0) << endl;
  }
}
int bfs(int cou, int now) {
  if (cou == 4) {
    if (now == n)
      return 1;
    else
      return 0;
  }
  int num = 0;
  for (int i = 0; i < 1000; i++) {
    if (i + now > n) break;
    num += bfs(cou + 1, now + i);
  }
  return num;
}
