#include <cstdio>
#include <iostream>
#include <algorithm>
#include <vector>
using namespace std;

struct Point {
	double x, y;
	Point(){}
	Point(double x,double y):x(x),y(y){}
	bool operator <(const Point &p) const {
	return x < p.x || (x == p.x && y < p.y);
	}
};

double cross(const Point &O, const Point &A, const Point &B){
	return (A.x - O.x) * (B.y - O.y) - (A.y - O.y) * (B.x - O.x);
}

int convex_hull(vector<Point> P){
	int n = P.size(), k = 0;
	vector<Point> H(2*n);
	sort(P.begin(), P.end());
	for (int i = 0; i < n; i++) {
		while (k >= 2 && cross(H[k-2], H[k-1], P[i]) <= 0.0) k--;
		H[k++] = P[i];
	}
	for (int i = n-2, t = k+1; i >= 0; i--) {
		while (k >= t && cross(H[k-2], H[k-1], P[i]) <= 0.0) k--;
		H[k++] = P[i];
	}
	return k-1;
}
int main(){
	int n;
	while(scanf("%d",&n),n){
		vector < Point > vp;
		for(int i = 0; i < n; i++){
			double x,y;
			scanf("%lf,%lf",&x,&y);
			vp.push_back(Point(x,y));
		}
		printf("%d\n",n-convex_hull(vp));
	}
}