#include<bits/stdc++.h>
using namespace std;
#define fi first
#define se second
typedef pair<int, int> pii;


int n;
map<pii, int> m;
vector<pii> v;
int main(){
	ios::sync_with_stdio(0);
	cin>>n;
	for(int i=0; i<n; ++i){
		int x,y;
		cin>>x>>y;
		v.push_back(pii(x,y));
	}
	for(int i=0; i<n; ++i)
		for(int j=0; j<n; ++j){
			if(i!=j){
				m[pii(v[i].fi-v[j].fi, v[i].se-v[j].se)]++;
				m[pii(v[j].fi-v[i].fi, v[j].se-v[i].se)]++;
			}
		}
	int cnt=0;
	for(auto x:m){
		//cout<< x.fi.fi <<' ' << x.fi.se <<' ' << x.se <<endl;
		if(x.se>=n){
			cnt++;
		}
	}
	cout<<cnt<<'\n';
}


