import sys

def side(p1, p2, p3):

  y1,x1=p1

  y2,x2=p2

  y3,x3=p3

  return (x3-x1)*(y2-y1)-(x2-x1)*(y3-y1)>0

while 1:

  n=eval(input())

  if n==0:break

  D=sorted([list(eval(input())) for i in range(n)])

  p1=D[0]

  D1=D[:]

  while True:

    for p2 in D1:

      if p1==p2:continue

      for p3 in D[::-1]:

        if p1==p3 or p2==p3: continue

        if side(p1,p2,p3)==0:break

      else:break

    p1=p2

    D1.remove(p2)

    if p2==D[0]:break

  print(len(D1))
import sys

def side(p1,p2):

  global D

  y1,x1=p1

  y2,x2=p2

  dy=y2-y1

  dx=x2-x1

  for p3 in D[::-1]:

    if p1==p3 or p2==p3:continue

    y3,x3=p3

    if (x3-x1)*dy-dx*(y3-y1)<0:return 0

  else:return 1



while 1:

  n=eval(input())

  if n==0:break

  D=sorted([list(eval(input())) for i in range(n)])

  p=p1=D[0]

  D1=D[:]

  while True:

    for p2 in D1:

      if p1!=p2 and side(p1,p2):break

    p1=p2

    D1.remove(p2)

    if p2==p:break

  print(len(D1))
import sys


def side(p1, p2, p3):
    y1, x1 = p1
    y2, x2 = p2
    y3, x3 = p3
    return (x3 - x1) * (y2 - y1) - (x2 - x1) * (y3 - y1) > 0


while 1:
    n = eval(input())
    if n == 0:
        break
    D = sorted([list(eval(input())) for i in range(n)])
    p1 = D[0]
    D1 = D[:]
    while True:
        for p2 in D1:
            if p1 == p2:
                continue
            for p3 in D[::-1]:
                if p1 == p3 or p2 == p3:
                    continue
                if side(p1, p2, p3) == 0:
                    break
            else:
                break
        p1 = p2
        D1.remove(p2)
        if p2 == D[0]:
            break
    print(len(D1))

import sys


def side(p1, p2):
    global D
    y1, x1 = p1
    y2, x2 = p2
    dy = y2 - y1
    dx = x2 - x1
    for p3 in D[::-1]:
        if p1 == p3 or p2 == p3:
            continue
        y3, x3 = p3
        if (x3 - x1) * dy - dx * (y3 - y1) < 0:
            return 0
    else:
        return 1


while 1:
    n = eval(input())
    if n == 0:
        break
    D = sorted([list(eval(input())) for i in range(n)])
    p = p1 = D[0]
    D1 = D[:]
    while True:
        for p2 in D1:
            if p1 != p2 and side(p1, p2):
                break
        p1 = p2
        D1.remove(p2)
        if p2 == p:
            break
    print(len(D1))

-def side(p1, p2, p3): +def side(p1, p2): +    global D -    y3, x3 = p3 -    return (x3 - x1) * (y2 - y1) - (x2 - x1) * (y3 - y1) > 0 +    dy = y2 - y1 +    dx = x2 - x1 +    for p3 in D[::-1]: +        if p1 == p3 or p2 == p3: +            continue +        y3, x3 = p3 +        if (x3 - x1) * dy - dx * (y3 - y1) < 0: +            return 0 +    else: +        return 1 -    p1 = D[0] +    p = p1 = D[0] -            if p1 == p2: -                continue -            for p3 in D[::-1]: -                if p1 == p3 or p2 == p3: -                    continue -                if side(p1, p2, p3) == 0: -                    break -            else: +            if p1 != p2 and side(p1, p2): -        if p2 == D[0]: +        if p2 == p: