from collections import *

N = int(input())
xy = [tuple(map(int, input().split())) for _ in range(N)]

if N==1:
    print(1)
    exit()
    
cnt = defaultdict(int)

for i in range(N):
    for j in range(N):
        if i==j:
            continue
        
        cnt[(xy[i][0]-xy[j][0], xy[i][1]-xy[j][1])] += 1

M = max(list(cnt.values()))
print(N-M) from collections import * 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 xy = [tuple(map(int, input().split())) for _ in range(N)] xy [tuple(map(int, input().split())) for _ in range(N)] if N==1:
    print(1)
    exit()
     N==1 N 1 print(1) print 1 exit() exit cnt = defaultdict(int) cnt defaultdict(int) defaultdict int for i in range(N):
    for j in range(N):
        if i==j:
            continue
        
        cnt[(xy[i][0]-xy[j][0], xy[i][1]-xy[j][1])] += 1 i range(N) range N for j in range(N):
        if i==j:
            continue
        
        cnt[(xy[i][0]-xy[j][0], xy[i][1]-xy[j][1])] += 1 j range(N) range N if i==j:
            continue
        
         i==j i j continue cnt[(xy[i][0]-xy[j][0], xy[i][1]-xy[j][1])] += 1 cnt[(xy[i][0]-xy[j][0], xy[i][1]-xy[j][1])] cnt (xy[i][0]-xy[j][0], xy[i][1]-xy[j][1]) xy[i][0]-xy[j][0] xy[i][0] [i] xy i 0 xy[j][0] [j] xy j 0 xy[i][1]-xy[j][1] xy[i][1] [i] xy i 1 xy[j][1] [j] xy j 1 1 M = max(list(cnt.values())) M max(list(cnt.values())) max list(cnt.values()) list cnt.values() cnt.values cnt values print(N-M) print N-M N M N = int(input()) int(input()) N M = max(list(cnt.values())) max(list(cnt.values())) M xy = [tuple(map(int, input().split())) for _ in range(N)] [tuple(map(int, input().split())) for _ in range(N)] xy cnt = defaultdict(int) defaultdict(int) cnt
from collections import *

N = int(input())
xy = [tuple(map(int, input().split())) for _ in range(N)]

if N==1:
    print(1)
    exit()
    
cnt = defaultdict(int)

for i in range(N):
    for j in range(N):
        if i==j:
            continue
        
        cnt[(xy[i][0]-xy[j][0], xy[i][1]-xy[j][1])] += 1

M = max(list(cnt.values()))
print(N-M)