#include <iostream>
#include <vector>
#include <string>
#include <stack>
#include <queue>
#include <deque>
#include <set>
#include <map>
#include <algorithm>	// require sort next_permutation count etc.
#include <cstdlib>	// require abs
#include <cstdio>	// require printf
#include <functional>
#include <numeric>	// require accumulate
#include <cmath>		// require sqrt ceil floor
#include <climits>	// require INT_MAX etc
#include <limits>
#include <cfloat>
#include <iomanip>	// require setw
#include <sstream>	// require stringstream 
#include <cstring>	// require memset
#include <cctype>	// require tolower, toupper
#include <stdint.h>	// require uint64_t
#include <fstream>	// require freopen
#include <complex>

using namespace std;

typedef complex<double> P;

const int MAX_LEN = 4000.0;
const int MAX_ARG = M_PI;

// àÏ (dot product) : a&#8901;b = |a||b|cosÆ
double dot(P a, P b)
{
	double res = a.real() * b.real() + a.imag() * b.imag();

	return res;
}
// OÏ (cross product) : a~b = |a||b|sinÆ

double cross(P a, P b)
{
	double res = a.real() * b.imag() - a.imag() * b.real();

  return res;
}

double stod (string str )
{
	stringstream ss (str );
	double res;

	ss >> res;

	return res;
}

bool cmp (P a, P b )
{
	if (a.imag() != b.imag() )
		return a.imag() < b.imag();

	return a.real() < b.real();
}

int main()
{
//	cut here before submit 
//	freopen ("testcase.epl", "r", stdin );
	int n;

	while (cin >> n && n ){

		vector <P> pos (n);
		for (int i = 0; i < n; ++i ){
			string str = "";
			cin >> str;
			double x = stod (str.substr (0, str.find (',') ) );
			double y = stod (str.substr (str.find (',')+1) );
			P p;
			p.real() = x;
			p.imag() = y;
			pos[i] = p;
		} // end for
		sort (pos.begin(), pos.end(), cmp );

		vector <int> used (n, 0 );
//		used[0] = 1;
		P start = pos[0];
		P curr = pos[0];
		P base;
		base.real() = 1.0;
		base.imag() = 0.0;

		P next, prev;

		double len = MAX_LEN;
		double min_arg = M_PI;
		int nd = -1;

		for (int i = 1; i < n; ++i ){
//			if (used[i] )
//				continue;
			P b = base;
			P c = pos[i] - curr;
			double d = dot (b, c );
			double a = 0.0;
			if (d < 0.0 ){	
					a = M_PI/2.;
				} // end if
			a += acos (fabs(d )/abs(b )/abs (c ) );
			if (min_arg >= a ){
				if (min_arg == a && len > abs (c ) )  {
					next = pos[i];
					nd = i;
					len = MAX_LEN;
				}else{
					min_arg = a;
					next = pos[i];
					nd = i;
					len = min (len, abs (c ) );
				} // en dif
			} // end if
		} // end for
		if (nd != - 1 ) 
			used[nd] = 1;

		prev = next;
		base = curr;
		do{
			len = MAX_LEN;
			min_arg = M_PI;
			nd = -1;
			for (int i = 0; i < n; ++i ){

				if (used[i] )
					continue;
				
				P b = prev - base;
				P c = pos[i] - base;
				double d = dot (b, c );
				double a = 0.0;
				if (d < 0.0 ){
					a = M_PI/2.;
				} // end if
			
				a += acos (fabs(d)/ abs (b) / abs (c ) );

				if (min_arg >= a ) {
					if (min_arg == a && len > abs (c ) ) {
						len = abs (c );
						next = pos[i];
						nd = i;
					}else{
						min_arg = a;
						next = pos[i];
						nd = i;
						len = min (len, abs (c ) );
					} // en dif
				} // end if
			} // end for

			if (nd != -1 ) 
				used[nd] = 1;
			base = prev;
			prev = next;

//		}while (next != start && (int)count (used.begin(), used.end(),1 ) != n );
		}while (prev != start );

		int res = (int)count (used.begin(), used.end(), 0 );	

		cout << res << endl;	

	} // end loop

		
	return 0;
}