include Math

until (n = $<.gets.to_i).zero?
  points = Array.new(n) { Complex(*$<.gets.split(",").map(&:to_f))  }
  ym = points.map(&:imaginary).max
  start_po = po0 = points.find {|po| po.imaginary == ym}
  prev_arg = PI
  result = loop do
    points = (points - [start_po] + [po0]).uniq
    idx = points.map.with_index {|po, i| [po - start_po, i]}
      .reject {|pos| pos.first == 0}
      .sort_by {|pos| a = pos.first.angle + PI - prev_arg; a >= 0 ? a : a + 2 * PI}
      .first.last
    selected = points[idx]
    points.select! {|po| po != start_po}
    if selected == po0
      break points.size - 1
    else
      prev_arg = (selected - start_po).angle + PI
      start_po = selected
    end
  end
  puts result
end
