#include <bits/stdc++.h>
using namespace std;
int v[100005], freq[100005];
int freq2[100005], x[1005], y[1005];
map<double, long long> m;
map<pair<double, double>, long long> ok;
double INF = 1e9;
int main() {
  cin.tie(0)->sync_with_stdio(0);
  cin.tie(NULL);
  cout.tie(NULL);
  int n;
  cin >> n;
  for (int i = 1; i <= n; i++) {
    cin >> x[i] >> y[i];
  }
  for (int i = 1; i <= n; i++) {
    for (int j = i + 1; j <= n; j++) {
      double panta, pct;
      if (x[i] == x[j]) {
        panta = INF;
        pct = x[i];
      } else {
        panta = 1.0 * (1.0 * (y[i] - y[j]) / (1.0 * (x[i] - x[j])));
        pct = 1.0 * (1.0 * y[i] - 1.0 * panta * 1.0 * x[i]);
      }
      if (ok[{panta, pct}] == 1) {
      } else {
        ok[{panta, pct}] = 1;
        m[panta]++;
      }
    }
  }
  long long sol = 0;
  map<double, long long>::iterator it;
  int nr = 0;
  for (it = m.begin(); it != m.end(); it++) {
    sol = sol + 1LL * (it->second) * 1LL * ((it->second) - 1) / 2;
  }
  long long total = 1LL * (ok.size()) * (ok.size() - 1) / 2;
  cout << total - sol;
}
