# input()
# int(input())
# map(int, input().split())
# list(map(int, input().split()))
# list(map(int, list(input()))) # スペースがない数字リストを読み込み
import math
import sys
import bisect
import heapq  # 優先度付きキュー(最小値取り出し)
from collections import deque
inf = 10**18
mod = 10**9+7

n = int(input())
xy = [list(map(int, input().split())) for i in range(n)]
xsub = 0
dicx = {}
xy.sort(reverse=True)
for i in range(n-1):
    for j in range(i+1,n):
        prex,prey = xy[i]
        x, y = xy[j]
        tmpx = x - prex
        tmpy = y - prey
        if (tmpx, tmpy) in dicx:
            dicx[(tmpx, tmpy)] += 1
        else:
            dicx[(tmpx, tmpy)] = 1
for _,num in dicx.items():
    xsub = max(num, xsub)
print(n-xsub)



 import math math import sys sys import bisect bisect import heapq heapq from collections import deque inf = 10**18 inf 10**18 10 18 mod = 10**9+7 mod 10**9+7 10**9 10 9 7 n = int(input()) n int(input()) int input() input list(map(int, input().split())) for i in range(n) for i in range(n) i range(n) range n for i in range(n) list(map(int, input().split())) list map(int, input().split()) map int input().split() ().split () input split xy = [list(map(int, input().split())) for i in range(n)] xy [list(map(int, input().split())) for i in range(n)] xsub = 0 xsub 0 dicx = {} dicx {} xy.sort(reverse=True) xy.sort xy sort reverse=True reverse True for i in range(n-1):
    for j in range(i+1,n):
        prex,prey = xy[i]
        x, y = xy[j]
        tmpx = x - prex
        tmpy = y - prey
        if (tmpx, tmpy) in dicx:
            dicx[(tmpx, tmpy)] += 1
        else:
            dicx[(tmpx, tmpy)] = 1 i range(n-1) range n-1 n 1 for j in range(i+1,n):
        prex,prey = xy[i]
        x, y = xy[j]
        tmpx = x - prex
        tmpy = y - prey
        if (tmpx, tmpy) in dicx:
            dicx[(tmpx, tmpy)] += 1
        else:
            dicx[(tmpx, tmpy)] = 1 j range(i+1,n) range i+1 i 1 n prex,prey = xy[i] prex xy[i] xy i prey x, y = xy[j] x xy[j] xy j y tmpx = x - prex tmpx x - prex x prex tmpy = y - prey tmpy y - prey y prey if (tmpx, tmpy) in dicx:
            dicx[(tmpx, tmpy)] += 1
        else:
            dicx[(tmpx, tmpy)] = 1 (tmpx, tmpy) in dicx (tmpx, tmpy) tmpx tmpy dicx dicx[(tmpx, tmpy)] += 1 dicx[(tmpx, tmpy)] dicx (tmpx, tmpy) tmpx tmpy 1 dicx[(tmpx, tmpy)] = 1 dicx[(tmpx, tmpy)] dicx (tmpx, tmpy) tmpx tmpy 1 for _,num in dicx.items():
    xsub = max(num, xsub) _ num dicx.items() dicx.items dicx items xsub = max(num, xsub) xsub max(num, xsub) max num xsub print(n-xsub) print n-xsub n xsub mod = 10**9+7 10**9+7 mod xsub = 0 0 xsub xy = [list(map(int, input().split())) for i in range(n)] [list(map(int, input().split())) for i in range(n)] xy dicx = {} {} dicx prey = xy[i] xy[i] prey y = xy[j] xy[j] y inf = 10**18 10**18 inf n = int(input()) int(input()) n xsub = max(num, xsub) max(num, xsub) xsub prex,prey = xy[i] xy[i] prex x, y = xy[j] xy[j] x tmpx = x - prex x - prex tmpx tmpy = y - prey y - prey tmpy
# input()
# int(input())
# map(int, input().split())
# list(map(int, input().split()))
# list(map(int, list(input()))) # スペースがない数字リストを読み込み
import math
import sys
import bisect
import heapq  # 優先度付きキュー(最小値取り出し)
from collections import deque
inf = 10**18
mod = 10**9+7

n = int(input())
xy = [list(map(int, input().split())) for i in range(n)]
xsub = 0
dicx = {}
xy.sort(reverse=True)
for i in range(n-1):
    for j in range(i+1,n):
        prex,prey = xy[i]
        x, y = xy[j]
        tmpx = x - prex
        tmpy = y - prey
        if (tmpx, tmpy) in dicx:
            dicx[(tmpx, tmpy)] += 1
        else:
            dicx[(tmpx, tmpy)] = 1
for _,num in dicx.items():
    xsub = max(num, xsub)
print(n-xsub)




