n=int(eval(input()))

M=[]

for i in range(n):

    x,y=list(map(int,input().split()))

    M.append([x,y])

M.sort(key=lambda x:(x[0],x[1]))

X=[]

Y=[]

for i in range(n-1):

    for j in range(i+1,n):

        a=M[i][0]-M[j][0]

        b=M[i][1]-M[j][1]

        if not [a,b] in Y:

            Y.append([a,b])

            X.append(1)

        else:

            X[Y.index([a,b])]+=1

ans=n

for i in range(len(Y)):

    ans=min(ans,n-X[i])

print(ans)
from collections import defaultdict as de

X=de(int)

n=int(eval(input()))

a=sorted([list(map(int,input().split()))for i in range(n)])

for i in range(n):

    for j in range(i):

        X[(a[i][0]-a[j][0],a[i][1]-a[j][1])]+=1

print((n-max(list(X.values()),default=0)))
n = int(eval(input()))
M = []
for i in range(n):
    x, y = list(map(int, input().split()))
    M.append([x, y])
M.sort(key=lambda x: (x[0], x[1]))
X = []
Y = []
for i in range(n - 1):
    for j in range(i + 1, n):
        a = M[i][0] - M[j][0]
        b = M[i][1] - M[j][1]
        if not [a, b] in Y:
            Y.append([a, b])
            X.append(1)
        else:
            X[Y.index([a, b])] += 1
ans = n
for i in range(len(Y)):
    ans = min(ans, n - X[i])
print(ans)

from collections import defaultdict as de

X = de(int)
n = int(eval(input()))
a = sorted([list(map(int, input().split())) for i in range(n)])
for i in range(n):
    for j in range(i):
        X[(a[i][0] - a[j][0], a[i][1] - a[j][1])] += 1
print((n - max(list(X.values()), default=0)))

+from collections import defaultdict as de + +X = de(int) -M = [] +a = sorted([list(map(int, input().split())) for i in range(n)]) -    x, y = list(map(int, input().split())) -    M.append([x, y]) -M.sort(key=lambda x: (x[0], x[1])) -X = [] -Y = [] -for i in range(n - 1): -    for j in range(i + 1, n): -        a = M[i][0] - M[j][0] -        b = M[i][1] - M[j][1] -        if not [a, b] in Y: -            Y.append([a, b]) -            X.append(1) -        else: -            X[Y.index([a, b])] += 1 -ans = n -for i in range(len(Y)): -    ans = min(ans, n - X[i]) -print(ans) +    for j in range(i): +        X[(a[i][0] - a[j][0], a[i][1] - a[j][1])] += 1 +print((n - max(list(X.values()), default=0)))