#include <vector>
#include <iostream>
#include <cstdio>
struct Point {
	double x, y;
	Point(const double &argx = 0, const double &argy = 0) :x(argx), y(argy) {};
	Point operator+(const Point &other) const { return Point(x + other.x, y + other.y); }
	Point operator-(const Point &other) const { return Point(x - other.x, y - other.y); }
	Point operator-() const { return Point(-x, -y); }
	bool operator>(const Point &other) const { return (y > other.y) || (y == other.y && x > other.x); }
	bool operator<(const Point &other) const { return (y < other.y) || (y == other.y && x < other.x); }
	bool operator==(const Point &other) const { return (y == other.y) && (x == other.x); }
	void inspect() const { std::cout << "(" << x << "," << y << ")" << "\n"; }
};
struct Vector {
	Vector(const int &x = 0, const int &y = 0) :origin(0, 0), vector(x, y) {};
	Vector(const Point &p1, const Point &p2) :origin(p1), vector(p2 - p1) {};
	Vector operator+(const Vector &other) const { return Vector(origin, origin + vector + other.vector); }
	Vector operator-(const Vector &other) const { return Vector(origin, origin + vector - other.vector); }
	Vector operator-() const { return Vector(origin, -vector); }
	double operator*(const Vector &other) const { return vector.x * other.vector.x + vector.y * other.vector.y; }
	double cross(const Vector &other) const { return vector.x * other.vector.y - vector.y * other.vector.x; }
	void inspect() const { vector.inspect(); }
	Point origin, vector;
};
template <class T>
void sort(std::vector<T> &vector, const int &left, const int &right) {
	if (left < right) {
		auto pivot = vector.at(left + (right - left) / 2);
		auto l = left, r = right;
		while (l < r) {
			while (pivot < vector.at(l))++l;
			while (pivot > vector.at(r))--r;
			if (l < r) {
				auto temp = vector.at(l);
				vector.at(l) = vector.at(r); vector.at(r) = temp;
				++l; --r;
			}
		}
		sort(vector, left, r); sort(vector, r + 1, right);
	}
}
int main() {
	constexpr double LES = 0.0000000001;
	int n;
	std::cin >> n;
	while (n != 0) {
		std::vector<Point> point(n);
		for (auto i = 0; i < n; ++i) {
			double x, y;
			std::scanf("%lf,%lf", &x, &y);
			point.at(i) = Point(x, y);
		}
		sort(point, 0, n - 1);
		auto func = [](const Point &p1, const Point &p2, const Point &p3) {
			return Vector(p2, p1).cross(Vector(p2, p3));
		};
		int sum = 0;
		std::vector<Point> stack(n + 2);
		stack.at(0) = point.at(0); stack.at(1) = point.at(0);
		auto idx = 1;
		for (auto &p : point) {
			while (func(stack.at(idx - 1), stack.at(idx), p) > LES) {
				--idx;
			}
			stack.at(++idx) = p;
		}
		sum += idx - 1;
		idx = 1;
		for (auto &p : point) {
			while (func(stack.at(idx - 1), stack.at(idx), p) < -LES) {
				--idx;
			}
			stack.at(++idx) = p;
		}
		sum += idx - 1;
		std::cout << n - sum + 2 << std::endl;
		std::cin >> n;
	}
	return 0;
}