#include <bits/stdc++.h>
using namespace std;
struct node {
  int x, y;
} m[100005];
int gcd(int x, int y) {
  int t;
  while (y) {
    t = x % y;
    x = y;
    y = t;
  }
  return x;
}
map<pair<int, int>, set<int>> q;
int n;
int main() {
  scanf("%d", &n);
  for (int i = 0; i < n; i++) scanf("%d%d", &m[i].x, &m[i].y);
  long long res = 0, cnt = 0;
  for (int i = 0; i < n - 1; i++) {
    for (int j = i + 1; j < n; j++) {
      int x1 = m[i].x, y1 = m[i].y, x2 = m[j].x, y2 = m[j].y;
      int a = y1 - y2, b = x1 - x2;
      int t = gcd(a, b);
      a /= t, b /= t;
      if (a < 0 || (a == 0 && b < 0)) {
        a = -a;
        b = -b;
      }
      long long c = 1LL * a * x1 - 1LL * b * y1;
      pair<int, int> l(a, b);
      if (!q[l].count(c)) {
        cnt++;
        q[l].insert(c);
        res += cnt - q[l].size();
      }
    }
  }
  cout << res << endl;
  return 0;
}
