using System; using System.Collections.Generic; using System.IO; using System.Linq; using System.Runtime.CompilerServices; using System.Text; using System.Threading.Tasks; namespace yukicore { internal class Program { private static void Main(string[] args) { int[] items = new int[10]; int num=int.Parse( Console.ReadLine()); int ans = 0; int sum = 0; int p = 0; int c = 0; int now = 0; int next = 0; while (true) { var tmps = Console.ReadLine(); if (tmps==null||tmps=="") break; p = 0; int lng =tmps.Length; var tmp = tmps.GetEnumerator(); tmp.MoveNext(); now = tmp.Current; tmp.MoveNext(); next = tmp.Current; if (next - 49 < -1) { items[now - 49]++; } else { items[9]++; tmp.MoveNext(); } tmp.MoveNext(); now = tmp.Current; tmp.MoveNext(); next = tmp.Current; if (next - 49 < -1) { items[now - 49]++; } else { items[9]++; tmp.MoveNext(); } tmp.MoveNext(); now = tmp.Current; bool f= tmp.MoveNext(); if(f) items[now - 49]++; else { items[9]++; } } for (int i = 0; i < 10; i++) { ans += items[i] >> 1; sum += items[i] & 0x1; } sum >>= 2; Console.WriteLine(ans + sum); } } }