import math N = int(input()) li = [] match = 0 other = 0 for i in range(N): l = list(map(int, input().split())) li.extend(l) for i in range(1,11): count = li.count(i) if count >= 2: match += math.floor(count / 2) other += count % 2 else: other += count print(int(match + (other / 4)))