import sys # sys.setrecursionlimit(200005) # sys.set_int_max_str_digits(1000005) int1 = lambda x: int(x)-1 pDB = lambda *x: print(*x, end="\n", file=sys.stderr) p2D = lambda x: print(*x, sep="\n", end="\n\n", file=sys.stderr) def II(): return int(sys.stdin.readline()) def LI(): return list(map(int, sys.stdin.readline().split())) def LLI(rows_number): return [LI() for _ in range(rows_number)] def LI1(): return list(map(int1, sys.stdin.readline().split())) def LLI1(rows_number): return [LI1() for _ in range(rows_number)] def SI(): return sys.stdin.readline().rstrip() dij = [(0, 1), (-1, 0), (0, -1), (1, 0)] # dij = [(0, 1), (-1, 0), (0, -1), (1, 0), (1, 1), (1, -1), (-1, 1), (-1, -1)] inf = (1 << 63)-1 # md = 10**9+7 md = 998244353 def arg_sort(xy): def msort(xx): if not xx: return n = len(xx) a = [xx, xx[:]] lr = [(0, n, 1, 0)] while lr: l, r, f, g = lr.pop() m = (l+r)//2 if f: lr.append((l, r, 0, g)) if m-l > 1: lr.append((l, m, 1, g ^ 1)) if r-m > 1: lr.append((m, r, 1, g ^ 1)) else: i, j, p, q = l, m, m-1, r-1 a1 = a[g] a2 = a[g ^ 1] for k in range((r-l)//2): x, y = a2[i] s, t = a2[j] if s*y-t*x > 0: a1[l+k] = a2[j] j += 1 else: a1[l+k] = a2[i] i += 1 x, y = a2[p] s, t = a2[q] if s*y-t*x > 0: a1[r-1-k] = a2[p] p -= 1 else: a1[r-1-k] = a2[q] q -= 1 if (r-l) & 1: a1[m] = a2[i] if i == p else a2[j] z1, z2, z3, z4, z5 = [], [], [], [], [] for x, y in xy: if x == y == 0: z5.append((x, y)) elif y >= 0: if x >= 0: z1.append((x, y)) else: z2.append((x, y)) else: if x < 0: z3.append((x, y)) else: z4.append((x, y)) msort(z1) msort(z2) msort(z3) msort(z4) return z1+z2+z3+z4+z5 n = II() xy = LLI(n) def ok(st): for i in range(n-2): x, y = st[i] s, t = st[i+1] if x*t-s*y == 0 and x*s >= 0 and y*t >= 0: return True return False ans = 0 for x, y in xy: st = [(s-x, t-y) for s, t in xy if s != x or t != y] st = arg_sort(st) ans += ok(st) print(ans)