#include <bits/stdc++.h>
using namespace std;
map<pair<pair<long long, long long>, pair<long long, long long> >, long long>
    mymap;
map<pair<pair<long long, long long>, pair<long long, long long> >,
    long long>::iterator it;
using namespace std;
vector<pair<long long, long long> > points;
long long gcd(long long a, long long b) {
  if (b == 0)
    return a;
  else
    return gcd(b, a % b);
}
long long mod(long long a) {
  if (a < 0)
    return -a;
  else
    return a;
}
long long sqrti(long long n) {
  long long i = 1;
  while (i * i != n) i++;
  return i;
}
int main() {
  long long n, x, y, temp, a, b, sum = 0, gc;
  pair<pair<long long, long long>, pair<long long, long long> > l;
  pair<long long, long long> p1, p2, a1, a2;
  cin >> n;
  for (long long i = 0; i < n; ++i) {
    cin >> x >> y;
    points.push_back(pair<long long, long long>(x, y));
  }
  for (long long i = 0; i < n; ++i) {
    for (long long j = i + 1; j < n; ++j) {
      p1 = points[i];
      p2 = points[j];
      if (p2.first != p1.first) {
        x = p2.second - p1.second;
        y = p2.first - p1.first;
        gc = gcd(mod(x), mod(y));
        if (gc) {
          x /= gc;
          y /= gc;
        }
        if (x * y < 0)
          x = mod(x) + 10000000;
        else
          x = mod(x);
        y = mod(y);
        a1 = pair<long long, long long>(x, y);
        x = p1.second * p2.first - p2.second * p1.first;
        y = p2.first - p1.first;
        gc = gcd(mod(x), mod(y));
        if (gc) {
          x /= gc;
          y /= gc;
        }
        if (x * y < 0)
          x = mod(x) + 10000000;
        else
          x = mod(x);
        y = mod(y);
        a2 = pair<long long, long long>(x, y);
        l = pair<pair<long long, long long>, pair<long long, long long> >(a1,
                                                                          a2);
      } else
        l = pair<pair<long long, long long>, pair<long long, long long> >(
            pair<long long, long long>(0, 0),
            pair<long long, long long>(p1.first, 0));
      it = mymap.find(l);
      if (it != mymap.end())
        (it->second) = (it->second) + 1;
      else
        mymap.insert(
            pair<pair<pair<long long, long long>, pair<long long, long long> >,
                 long long>(l, 1));
    }
  }
  for (typeof(mymap.begin()) it1 = mymap.begin(); it1 != mymap.end(); it1++) {
    long long num = it1->second;
    l = it1->first;
    a = num;
    b = (1 + sqrti(num * 8 + 1)) / 2;
    sum += (a * (b - 2) / 3);
  }
  sum = n * (n - 1) * (n - 2) / 6 - sum;
  cout << sum << "\n";
}
