program main
  implicit none
  integer::i,j,k,count,kc,N
  integer,allocatable::x(:),y(:)
  integer,allocatable::dx(:),dy(:)
  
  read(*,*)N
  allocate(x(1:N),y(1:N))
  do i=1,N
     read(*,*)x(i),y(i)
  enddo

  allocate(dx(1:N*(N-1)/2),dy(1:N*(N-1)/2))
  k=1
  do i=1,N-1
     do j=i+1,N
        dx(k)=x(i)-x(j)
        dy(k)=y(i)-y(j)
        !write(6,*)k,dx(k),dy(k)
        k=k+1
     enddo
  enddo

  kc=0
  do i=1,N*(N-1)/2
     count=1
     do j=i+1,N*(N-1)/2
        if(dx(i).eq.dx(j).and.dy(i).eq.dy(j))then
           count=count+1
        endif
     enddo
     if(count.gt.kc)then
        kc=count
     endif
  enddo

  !write(6,*)

  write(6,*)N-kc
  
  stop
end program main
