n = int(input()) l = [0] * 11 for i in range(n): m = list(map(int, input().split())) for j in m: l[j] += 1 x, y = 0, 0 for i in l: x += i // 2 y += i % 2 print(x + y//4)