N = input()
s = set()
ans = 0
shuuhen = [(i, j) for i in xrange(-20, 21) for j in xrange(-20, 21) if i*i+j*j<400]
for i in xrange(N):
    x, y = map(int, raw_input().split())
    if (x, y) in s:
        continue
    for j, k in shuuhen:
        s.add((x+j, y+k))
    ans += 1
print ans