#include <bits/stdc++.h>
using namespace std;
struct pt {
  double x, y;
};
bool operator<(pt a, pt b) { return make_pair(a.x, a.y) < make_pair(b.x, b.y); }
int n;
vector<pt> p;
set<int> ver;
set<pair<double, double>> lines;
map<double, set<double>> linek;
long long ans, N;
void solve(pt a, pt b) {
  if (a.x == b.x)
    ver.insert(a.x);
  else {
    double K, B;
    K = (a.y - b.y) / (a.x - b.x);
    B = a.y - K * a.x;
    lines.insert(make_pair(K, B));
    linek[K].insert(B);
  }
}
int main() {
  cin >> n;
  for (int i = 1; i <= n; i++) {
    pt add;
    cin >> add.x >> add.y;
    p.push_back(add);
  }
  for (int i = 0; i < n; i++)
    for (int j = i + 1; j < n; j++) solve(p[i], p[j]);
  N = lines.size() + ver.size();
  ans = N * (N - 1) / 2ll;
  N = ver.size();
  ans -= N * (N - 1) / 2ll;
  for (auto it = linek.begin(); it != linek.end(); ++it) {
    N = it->second.size();
    ans -= N * (N - 1) / 2ll;
  }
  cout << ans << endl;
  return 0;
}
