using System; using System.Linq; class Program { static void Main() { int[] a = Console.ReadLine().Split().Select(int.Parse).ToArray(); string res = "NO HAND"; int cnt = 0; for (int i = 0; i < a.Length; i++) { for(int j = i + 1; j < a.Length; j++) { if (a[i] == a[j]) cnt++; } } switch (cnt) { case 1: res = "ONE PAIR"; break; case 2: res = "TWO PAIR"; break; case 3: res = "THREE CARD"; break; case 4: res = "FULL HOUSE"; break; } Console.WriteLine(res); } }