from collections import defaultdict
n = int(input())
points = [tuple(map(int, input().split())) for _ in range(n)]

cnt = defaultdict(int)
cnt[(0, 0)] = 0
for i in range(n):
    for j in range(n):
        if i == j:
            continue
        cnt[(points[i][0] - points[j][0], points[i][1] - points[j][1])] += 1

# print(cnt)
ans = n - max(cnt.values())
print(ans) from collections import defaultdict n = int(input()) n int(input()) int input() input tuple(map(int, input().split())) for _ in range(n) for _ in range(n) _ range(n) range n for _ in range(n) tuple(map(int, input().split())) tuple map(int, input().split()) map int input().split() ().split () input split points = [tuple(map(int, input().split())) for _ in range(n)] points [tuple(map(int, input().split())) for _ in range(n)] cnt = defaultdict(int) cnt defaultdict(int) defaultdict int cnt[(0, 0)] = 0 cnt[(0, 0)] cnt (0, 0) 0 0 0 for i in range(n):
    for j in range(n):
        if i == j:
            continue
        cnt[(points[i][0] - points[j][0], points[i][1] - points[j][1])] += 1

# print(cnt) i range(n) range n for j in range(n):
        if i == j:
            continue
        cnt[(points[i][0] - points[j][0], points[i][1] - points[j][1])] += 1

# print(cnt) j range(n) range n if i == j:
            continue
         i == j i j continue cnt[(points[i][0] - points[j][0], points[i][1] - points[j][1])] += 1 cnt[(points[i][0] - points[j][0], points[i][1] - points[j][1])] cnt (points[i][0] - points[j][0], points[i][1] - points[j][1]) points[i][0] - points[j][0] points[i][0] [i] points i 0 points[j][0] [j] points j 0 points[i][1] - points[j][1] points[i][1] [i] points i 1 points[j][1] [j] points j 1 1 ans = n - max(cnt.values()) ans n - max(cnt.values()) n max(cnt.values()) max cnt.values() cnt.values cnt values print(ans) print ans n = int(input()) int(input()) n cnt = defaultdict(int) defaultdict(int) cnt points = [tuple(map(int, input().split())) for _ in range(n)] [tuple(map(int, input().split())) for _ in range(n)] points ans = n - max(cnt.values()) n - max(cnt.values()) ans
from collections import defaultdict
n = int(input())
points = [tuple(map(int, input().split())) for _ in range(n)]

cnt = defaultdict(int)
cnt[(0, 0)] = 0
for i in range(n):
    for j in range(n):
        if i == j:
            continue
        cnt[(points[i][0] - points[j][0], points[i][1] - points[j][1])] += 1

# print(cnt)
ans = n - max(cnt.values())
print(ans)
