n = int(input())
ball = []
for i in range(n):
    ball.append(list(map(int, input().split())))

ans = 1000
for i in range(n):
    for j in range(n):
        if i == j:
            continue
        temp = 0
        x0, y0 = ball[i]
        x1, y1 = ball[j]
        p, q = x1-x0, y1-y0
        used = [False]*(n)
        for k in range(n):
            if not used[k]:
                temp += 1
                x0, y0 = ball[k]
                used[k] = True

                x, y = x0, y0
                while True:
                    f = 0
                    for l in range(n):
                        if used[l]:
                            continue
                        if x + p == ball[l][0] and y + q == ball[l][1]:
                            used[l] = True
                            x += p
                            y += q
                            f = 1
                    if f == 0:
                        break

                x, y = x0, y0
                while True:
                    f = 0
                    for l in range(n):
                        if used[l]:
                            continue
                        if x - p == ball[l][0] and y - q == ball[l][1]:
                            used[l] = True
                            x -= p
                            y -= q
                            f = 1
                    if f == 0:
                        break

        ans = min(ans, temp)

if n == 1:
    print(1)
else:
    print(ans) n = int(input()) n int(input()) int input() input ball = [] ball [] for i in range(n):
    ball.append(list(map(int, input().split()))) i range(n) range n ball.append(list(map(int, input().split()))) ball.append ball append list(map(int, input().split())) list map(int, input().split()) map int input().split() ().split () input split ans = 1000 ans 1000 for i in range(n):
    for j in range(n):
        if i == j:
            continue
        temp = 0
        x0, y0 = ball[i]
        x1, y1 = ball[j]
        p, q = x1-x0, y1-y0
        used = [False]*(n)
        for k in range(n):
            if not used[k]:
                temp += 1
                x0, y0 = ball[k]
                used[k] = True

                x, y = x0, y0
                while True:
                    f = 0
                    for l in range(n):
                        if used[l]:
                            continue
                        if x + p == ball[l][0] and y + q == ball[l][1]:
                            used[l] = True
                            x += p
                            y += q
                            f = 1
                    if f == 0:
                        break

                x, y = x0, y0
                while True:
                    f = 0
                    for l in range(n):
                        if used[l]:
                            continue
                        if x - p == ball[l][0] and y - q == ball[l][1]:
                            used[l] = True
                            x -= p
                            y -= q
                            f = 1
                    if f == 0:
                        break

        ans = min(ans, temp) i range(n) range n for j in range(n):
        if i == j:
            continue
        temp = 0
        x0, y0 = ball[i]
        x1, y1 = ball[j]
        p, q = x1-x0, y1-y0
        used = [False]*(n)
        for k in range(n):
            if not used[k]:
                temp += 1
                x0, y0 = ball[k]
                used[k] = True

                x, y = x0, y0
                while True:
                    f = 0
                    for l in range(n):
                        if used[l]:
                            continue
                        if x + p == ball[l][0] and y + q == ball[l][1]:
                            used[l] = True
                            x += p
                            y += q
                            f = 1
                    if f == 0:
                        break

                x, y = x0, y0
                while True:
                    f = 0
                    for l in range(n):
                        if used[l]:
                            continue
                        if x - p == ball[l][0] and y - q == ball[l][1]:
                            used[l] = True
                            x -= p
                            y -= q
                            f = 1
                    if f == 0:
                        break

        ans = min(ans, temp) j range(n) range n if i == j:
            continue
         i == j i j continue temp = 0 temp 0 x0, y0 = ball[i] x0 ball[i] ball i y0 x1, y1 = ball[j] x1 ball[j] ball j y1 p, q = x1-x0, y1-y0 p x1-x0 x1 x0 q y1-y0 y1 y0 used = [False]*(n) used [False]*(n) [False] False n for k in range(n):
            if not used[k]:
                temp += 1
                x0, y0 = ball[k]
                used[k] = True

                x, y = x0, y0
                while True:
                    f = 0
                    for l in range(n):
                        if used[l]:
                            continue
                        if x + p == ball[l][0] and y + q == ball[l][1]:
                            used[l] = True
                            x += p
                            y += q
                            f = 1
                    if f == 0:
                        break

                x, y = x0, y0
                while True:
                    f = 0
                    for l in range(n):
                        if used[l]:
                            continue
                        if x - p == ball[l][0] and y - q == ball[l][1]:
                            used[l] = True
                            x -= p
                            y -= q
                            f = 1
                    if f == 0:
                        break

         k range(n) range n if not used[k]:
                temp += 1
                x0, y0 = ball[k]
                used[k] = True

                x, y = x0, y0
                while True:
                    f = 0
                    for l in range(n):
                        if used[l]:
                            continue
                        if x + p == ball[l][0] and y + q == ball[l][1]:
                            used[l] = True
                            x += p
                            y += q
                            f = 1
                    if f == 0:
                        break

                x, y = x0, y0
                while True:
                    f = 0
                    for l in range(n):
                        if used[l]:
                            continue
                        if x - p == ball[l][0] and y - q == ball[l][1]:
                            used[l] = True
                            x -= p
                            y -= q
                            f = 1
                    if f == 0:
                        break

         not used[k] used[k] used k temp += 1 temp 1 x0, y0 = ball[k] x0 ball[k] ball k y0 used[k] = True used[k] used k True x, y = x0, y0 x x0 y y0 while True:
                    f = 0
                    for l in range(n):
                        if used[l]:
                            continue
                        if x + p == ball[l][0] and y + q == ball[l][1]:
                            used[l] = True
                            x += p
                            y += q
                            f = 1
                    if f == 0:
                        break

                 True f = 0 f 0 for l in range(n):
                        if used[l]:
                            continue
                        if x + p == ball[l][0] and y + q == ball[l][1]:
                            used[l] = True
                            x += p
                            y += q
                            f = 1
                     l range(n) range n if used[l]:
                            continue
                         used[l] used l continue if x + p == ball[l][0] and y + q == ball[l][1]:
                            used[l] = True
                            x += p
                            y += q
                            f = 1
                     x + p == ball[l][0] and y + q == ball[l][1] x + p == ball[l][0] x + p x p ball[l][0] [l] ball l 0 y + q == ball[l][1] y + q y q ball[l][1] [l] ball l 1 used[l] = True used[l] used l True x += p x p y += q y q f = 1 f 1 if f == 0:
                        break

                 f == 0 f 0 break x, y = x0, y0 x x0 y y0 while True:
                    f = 0
                    for l in range(n):
                        if used[l]:
                            continue
                        if x - p == ball[l][0] and y - q == ball[l][1]:
                            used[l] = True
                            x -= p
                            y -= q
                            f = 1
                    if f == 0:
                        break

         True f = 0 f 0 for l in range(n):
                        if used[l]:
                            continue
                        if x - p == ball[l][0] and y - q == ball[l][1]:
                            used[l] = True
                            x -= p
                            y -= q
                            f = 1
                     l range(n) range n if used[l]:
                            continue
                         used[l] used l continue if x - p == ball[l][0] and y - q == ball[l][1]:
                            used[l] = True
                            x -= p
                            y -= q
                            f = 1
                     x - p == ball[l][0] and y - q == ball[l][1] x - p == ball[l][0] x - p x p ball[l][0] [l] ball l 0 y - q == ball[l][1] y - q y q ball[l][1] [l] ball l 1 used[l] = True used[l] used l True x -= p x p y -= q y q f = 1 f 1 if f == 0:
                        break

         f == 0 f 0 break ans = min(ans, temp) ans min(ans, temp) min ans temp if n == 1:
    print(1)
else:
    print(ans) n == 1 n 1 print(1) print 1 print(ans) print ans y0 = ball[k] ball[k] y0 temp = 0 0 temp p, q = x1-x0, y1-y0 x1-x0 p ans = 1000 1000 ans q = x1-x0, y1-y0 y1-y0 q f = 0 0 f y -= q q y ball = [] [] ball y0 = ball[i] ball[i] y0 x1, y1 = ball[j] ball[j] x1 y += q q y y1 = ball[j] ball[j] y1 ans = min(ans, temp) min(ans, temp) ans n = int(input()) int(input()) n x, y = x0, y0 x0 x y = x0, y0 y0 y f = 1 1 f x -= p p x temp += 1 1 temp x0, y0 = ball[k] ball[k] x0 f = 0 0 f f = 1 1 f x0, y0 = ball[i] ball[i] x0 x += p p x used = [False]*(n) [False]*(n) used y = x0, y0 y0 y x, y = x0, y0 x0 x
n = int(input())
ball = []
for i in range(n):
    ball.append(list(map(int, input().split())))

ans = 1000
for i in range(n):
    for j in range(n):
        if i == j:
            continue
        temp = 0
        x0, y0 = ball[i]
        x1, y1 = ball[j]
        p, q = x1-x0, y1-y0
        used = [False]*(n)
        for k in range(n):
            if not used[k]:
                temp += 1
                x0, y0 = ball[k]
                used[k] = True

                x, y = x0, y0
                while True:
                    f = 0
                    for l in range(n):
                        if used[l]:
                            continue
                        if x + p == ball[l][0] and y + q == ball[l][1]:
                            used[l] = True
                            x += p
                            y += q
                            f = 1
                    if f == 0:
                        break

                x, y = x0, y0
                while True:
                    f = 0
                    for l in range(n):
                        if used[l]:
                            continue
                        if x - p == ball[l][0] and y - q == ball[l][1]:
                            used[l] = True
                            x -= p
                            y -= q
                            f = 1
                    if f == 0:
                        break

        ans = min(ans, temp)

if n == 1:
    print(1)
else:
    print(ans)
