using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace yuki { class Program { static void Main(string[] args) { int N = int.Parse(Console.ReadLine()); string str = Console.ReadLine(); string[] A = str.Split(); int cnt = 0; for (int i = 0; i < N; i++) { if (A[i].Length == str.Length - str.Replace(A[i], "").Length) { cnt++; } } Console.WriteLine(cnt); } } }