output_description: Print the minimum total cost required to collect all the balls.
  
  * * *
input_description: Input is given from Standard Input in the following format:
  
      
      
      N
      x_1 y_1
      :
      x_N y_N
attempt: n = int(input())
  l = [list(map(int, input().split())) for i in range(n)]
  u = []
  for i in range(n):
      ll = []
      for j in range(n):
          if j != i:
              ll.append([l[i][0] - l[j][0], l[i][1] - l[j][1]])
      u += ll
  su = 0
  for i in u:
      a = u.count(i)
      su = max(su, a)
  print(n - su)
  
problem_description: Statement
  
  There are N balls in a two-dimensional plane. The i-th ball is at coordinates
  (x_i, y_i).
  
  We will collect all of these balls, by choosing two integers p and q such that
  p \neq 0 or q \neq 0 and then repeating the following operation:
  
    * Choose a ball remaining in the plane and collect it. Let (a, b) be the coordinates of this ball. If we collected a ball at coordinates (a - p, b - q) in the previous operation, the cost of this operation is 0. Otherwise, including when this is the first time to do this operation, the cost of this operation is 1.
  
  Find the minimum total cost required to collect all the balls when we
  optimally choose p and q.
samples: [{"input": "2\n    1 1\n    2 2", "output": "1\n    \n\nIf we choose p = 1, q = 1, we can collect all the balls at a cost of 1 by\ncollecting them in the order (1, 1), (2, 2).\n\n* * *"}, {"input": "3\n    1 4\n    4 6\n    7 8", "output": "1\n    \n\nIf we choose p = -3, q = -2, we can collect all the balls at a cost of 1 by\ncollecting them in the order (7, 8), (4, 6), (1, 4).\n\n* * *"}, {"input": "4\n    1 1\n    1 2\n    2 1\n    2 2", "output": "2"}]