def distance(X, Y): return abs(X[0] - Y[0])**2 + abs(X[1] - Y[1])**2 n = int(input()) xy = [list(map(int, input().split())) for _ in range(n)] d = [] for i in range(n): for g in range(i+1, n): d.append((distance(xy[i], xy[g]), (i, g))) d.sort() delete = set() exploded = set() cnt = 0 used = [False]*n for i, x in d: if (x[0] in delete) or (x[1] in delete) or (x[0] in exploded) or (x[1] in exploded): continue if x[0] == 0: delete.add(x[1]) else: exploded.add(x[0]) exploded.add(x[1]) print(len(delete))