#include <bits/stdc++.h>
using namespace std;
const int N = 1e5 + 7;
const int Mod = 1e9 + 7;
const double Eps = 1e-8;
struct Node {
  int x, y;
} p[2005];
int Gcd(int x, int y) { return !y ? x : Gcd(y, x % y); }
struct FS {
  int x, y;
  FS() {}
  FS(int x_, int y_) {
    x = x_, y = y_;
    if (y < 0) x = -x, y = -y;
    int d = Gcd(x, y);
    x /= d, y /= d;
  }
  bool operator<(const FS& A) const {
    if (x != A.x) return x < A.x;
    return y < A.y;
  }
};
map<int, int> num;
map<pair<FS, FS>, int> M;
void Add(Node a, Node b) {
  FS k, bb;
  if (a.x == b.x)
    k = FS{(int)1e5, 1}, bb = FS{a.x, 1};
  else if (a.y == b.y)
    k = FS{0, 1}, bb = FS{a.y, 1};
  else {
    k = FS{a.y - b.y, a.x - b.x};
    bb = FS{a.y * k.y - k.x * a.x, k.y};
  }
  M[{k, bb}]++;
}
int n;
int main() {
  int tot = 0;
  for (int i = 1; i <= 2000; i++) {
    num[tot] = i;
    tot += i;
  }
  cin >> n;
  if (n <= 2) {
    puts("0");
    return 0;
  }
  for (int i = 0; i < n; i++) {
    scanf("%d%d", &p[i].x, &p[i].y);
  }
  for (int i = 0; i < n; i++)
    for (int j = i + 1; j < n; j++) {
      Add(p[i], p[j]);
    }
  long long ret = 1LL * n * (n - 1) * (n - 2) / 6;
  for (auto it : M) {
    int t = num[it.second];
    ret -= 1LL * t * (t - 1) * (t - 2) / 6;
  }
  cout << ret << endl;
}
