#include <iostream>
#include <algorithm>
#include <vector>
#include <cstdio>
#include <cmath>
#define EPS 1e-10
using namespace std;

double add(double a,double b){
	if(abs(a + b) < EPS * (abs(a) + abs(b))) return 0;
	return a + b;
}

struct vect{
	double x,y;
	vect(){}
	vect(double x,double y) : x(x),y(y){}
	vect operator + (vect v){
		return vect(add(x,v.x),add(y,v.y));
	}
	vect operator - (vect v){
		return vect(add(x,-v.x),add(y,-v.y));
	}
	vect operator * (double d){
		return vect(x * d,y * d);
	}
	double dot(vect v){
		return add(x * v.x,y * v.y);
	}
	double det(vect v){
		return add(x * v.y,-y * v.x);
	}
};

bool comp_vect(const vect& v1,const vect& v2){
	if(v1.x != v2.x) return v1.x < v2.x;
	return v1.y < v2.y;
}

vector<vect> convex(vect* ps,int n){
	sort(ps,ps + n,comp_vect);
	int k = 0;
	vector<vect> qs(n * 2);
	for(int i = 0;i < n;i++){
		while(k > 1 && (qs[k - 1] - qs[k - 2]).det(ps[i] - qs[k - 1]) <= 0.0) k--;
		qs[k++] = ps[i];
	}
	for(int i = n - 2,t = k;i >= 0;i--){
		while(k > t && (qs[k - 1] - qs[k - 2]).det(ps[i] - qs[k - 1]) <= 0.0) k--;
		qs[k++] = ps[i];
	}
	qs.resize(k - 1);
	return qs;
}

int main(){
	int n;
	while(cin >> n,n){
		vect ps[100];
		for(int i = 0;i < n;i++){
			double x,y;
			scanf("%lf,%lf",&x,&y);
			ps[i] = vect(x,y);
		}
		vector<vect> conv = convex(ps,n);
		cout << n - conv.size() << endl;
	}
	return 0;
}