10
-2 1
2 -2
-1 -2
0 0
2 -1
0 -2
2 2
0 2
-1 -1
1 -2
 40
-8 24
2 -1
1 -18
72 -70
5 -4
-308 436
-19 40
36 -35
-178 265
-1 2
-7 30
-1 0
3 -2
200 -285
17 -16
-35 74
0 -4
-86 106
-1 4
-7 6
0 1
-5 4
-2 3
6 -5
-4 5
181 -262
76 -118
0 0
-7 18
-58 104
-5 6
-6 12
-3 4
1 0
11 -10
-86 130
-3 6
153 -236
-183 270
-33 64
 5
0 -1
0 -2
0 -3
0 -4
0 -5
 10
0 1
-1 -1
1 1
-1 0
1 -1
-2 -1
-2 2
-2 0
0 -2
0 -1
 20
-1 18
-2 5
-5 4
2 -33
9 -18
0 0
11 -22
2 0
-1 2
-4 41
1 6
1 -2
6 -12
0 1
-3 6
3 -6
3 -8
-1 4
2 -5
1 0
 10
2 1
-1 0
-2 -1
-1 1
0 2
2 -2
0 0
-2 -2
0 -2
-2 1
 20
-3 -3
0 4
-3 1
1 1
-1 2
-4 4
3 -1
-3 0
0 2
4 0
2 3
2 4
4 -3
-4 3
-1 1
1 3
-2 4
1 -2
1 -1
3 0
 3
0 0
0 -1
0 1
 10
2 1
-1 1
0 0
-3 1
-2 -3
-1 -2
-1 -1
1 2
3 -2
0 -2
 3
3 3
1 2
1 1
 4
0 0
1 0
2 0
3 0
 9
1 1
1 0
0 1
0 0
-1 0
-1 1
-1 -1
1 -1
0 -1
 7
1 1
-1 -1
1 0
0 1
-1 0
0 -1
0 0

4
 57
 4
 5
 21
 4
 10
 1
 1
 0
 2
 8
 3

#include <bits/stdc++.h>
using namespace std;
const int MOD = 1000000007;
const long long INF = 1E18;
const double EPS = 1E-10;
template <class T>
T ckmin(T& a, T b) {
  return a = min(a, b);
}
template <class T>
T ckmax(T& a, T b) {
  return a = max(a, b);
}
namespace input {
template <class T1, class T2>
void re(pair<T1, T2>& p);
template <class T>
void re(vector<T>& a);
template <class T>
void re(T& x) {
  cin >> x;
}
void re(double& x) {
  string t;
  re(t);
  x = stod(t);
}
template <class A, class... As>
void re(A& head, As&... tail) {
  re(head);
  re(tail...);
}
template <class T1, class T2>
void re(pair<T1, T2>& p) {
  re(p.first, p.second);
}
template <class T>
void re(vector<T>& a) {
  for (int i = (0); i < (((int)(a).size())); i++) re(a[i]);
}
}  // namespace input
using namespace input;
namespace output {
template <class T1, class T2>
void pr(const pair<T1, T2>& x);
template <class T>
void pr(const vector<T>& x);
template <class T>
void pr(const set<T>& x);
template <class T1, class T2>
void pr(const map<T1, T2>& x);
template <class T>
void pr(const T& x) {
  cout << x;
}
template <class A, class... As>
void pr(const A& head, const As&... tail) {
  pr(head);
  pr(tail...);
}
template <class T1, class T2>
void pr(const pair<T1, T2>& x) {
  pr("{", x.first, ", ", x.second, "}");
}
template <class T>
void prc(const T& x) {
  pr("{");
  bool fi = 1;
  for (auto& a : x) pr(!fi ? ", " : "", a), fi = 0;
  pr("}");
}
template <class T>
void pr(const vector<T>& x) {
  prc(x);
}
template <class T>
void pr(const set<T>& x) {
  prc(x);
}
template <class T1, class T2>
void pr(const map<T1, T2>& x) {
  prc(x);
}
void ps() { pr("\n"); }
template <class A, class... As>
void ps(const A& head, const As&... tail) {
  pr(head, " ");
  ps(tail...);
}
}  // namespace output
using namespace output;
inline int cmp(double x, double y = 0, double tol = EPS) {
  return (x <= y + tol) ? (x + tol < y) ? -1 : 0 : 1;
}
int main() {
  cin.tie(0);
  ios::sync_with_stdio(0);
  int n;
  re(n);
  vector<pair<int, int> > p(n);
  re(p);
  map<double, int> m;
  for (auto u = begin(p); u != end(p); u++)
    for (auto v = next(u); v != end(p); v++)
      m[1. * (v->second - u->second) / (v->first - u->first)]++;
  long long ret = 0;
  for (auto& u : m)
    if (u.second > 2)
      ret += u.second * (long long)(sqrt(1. + 8 * u.second) + EPS - 3) / 6;
  ps(ret);
}
