#include <iostream>
#include <vector>
#include <algorithm>
#include <cassert>
typedef long long ll;
using namespace std;
struct point_t { double x, y; };
bool operator < (point_t const & a, point_t const & b) { return make_pair(a.x,a.y) < make_pair(b.x,b.y); }
point_t operator + (point_t const & a, point_t const & b) { return { a.x + b.x, a.y + b.y }; }
point_t operator - (point_t const & a, point_t const & b) { return { a.x - b.x, a.y - b.y }; }
double cross(point_t const & a, point_t const & b) { return a.x * b.y - a.y * b.x; }
double ccw(point_t const & a, point_t const & b, point_t const & c) { return cross(b - a, c - a); }
vector<point_t> convex_hull(vector<point_t> ps) {
    int n = ps.size();
    sort(ps.begin(), ps.end());
    vector<point_t> qs;
    for (int i = 0; i < n; ++i) { // lower hull
        int k = qs.size();
        while (k >= 2 and ccw(qs[k-2], qs[k-1], ps[i]) <= 0) {
            qs.pop_back();
            k = qs.size();
        }
        qs.push_back(ps[i]);
    }
    const int t = qs.size();
    for (int i = n-2; i >= 0; --i) { // upper hull
        int k = qs.size();
        while (k >= t and ccw(qs[k-2], qs[k-1], ps[i]) <= 0) {
            qs.pop_back();
            k = qs.size();
        }
        qs.push_back(ps[i]);
    }
    qs.pop_back();
    return qs;
}
int solve(vector<point_t> const & ps) {
    vector<point_t> qs = convex_hull(ps);
    return ps.size() - qs.size();
}
int main() {
    while (true) {
        int n; cin >> n;
        if (n == 0) break;
        vector<point_t> ps(n);
        char dummy;
        for (auto && p : ps) cin >> p.x >> dummy >> p.y;
        cout << solve(ps) << endl;
    }
    return 0;
}