using System; using System.Linq; class Program { public void Solve() { int N = int.Parse(Console.ReadLine()); int[] abc; int[] item = new int[11]; int powerup = 0; for (int i = 0; i < N; i++) { abc = Console.ReadLine().Split(' ').Select(s => int.Parse(s)).ToArray(); for (int j = 0; j < abc.Length; j++) { item[abc[j]]++; if (0 < item[abc[j]] / 2) { powerup += item[abc[j]] / 2; item[abc[j]] %= 2; } } } powerup += item.Sum() / 4; Console.WriteLine(powerup); } static void Main() { var solver = new Program(); solver.Solve(); } }