#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  long long n;
  cin >> n;
  vector<pair<long long, long long> > p;
  for (long long i = 0; i < n; i++) {
    double x, y;
    cin >> x >> y;
    p.push_back(make_pair(x, y));
  }
  set<pair<double, double> > s;
  set<double> e;
  long long c;
  for (long long i = 0; i < n; i++) {
    for (long long j = i + 1; j < n; j++) {
      double x1 = p[i].first;
      double y1 = p[i].second;
      double x2 = p[j].first;
      double y2 = p[j].second;
      if ((x2 - x1) != 0) {
        double m = (y2 - y1) / (x2 - x1);
        double c = y1 - m * (x1);
        s.insert(make_pair(m, c));
      } else {
        e.insert(x1);
      }
    }
  }
  set<pair<double, double> >::iterator it;
  vector<long long> r;
  long long k = 0;
  long long w = 0;
  set<pair<double, double> >::iterator itr;
  itr = s.begin();
  it = s.begin();
  it++;
  while (it != s.end()) {
    long long u = 0;
    pair<double, double> gg = *it;
    pair<double, double> hh = *itr;
    while (gg.first == hh.first) {
      u++;
      it++;
      itr++;
      gg = *it;
      hh = *itr;
    }
    if (u != 0) {
      w = w + ((u + 1) * u) / 2;
    }
    it++;
    itr++;
  }
  c = e.size();
  long long total = s.size() + c;
  total = (total * (total - 1)) / 2;
  w = w + ((c - 1) * c) / 2;
  cout << (total - w);
  return 0;
}
