using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace YukiCoder { public class Brother { public static void Main() { string[] A = Console.ReadLine().Split(' '); string[] B = Console.ReadLine().Split(' '); string[] C = Console.ReadLine().Split(' '); Dictionary> BroDic = new Dictionary>() { {"A",new List{int.Parse(A[0]),int.Parse(A[1])}}, {"B",new List{int.Parse(B[0]),int.Parse(B[1])}}, {"C",new List{int.Parse(C[0]),int.Parse(C[1])}}, }; foreach (var Value in BroDic.OrderByDescending(x => x.Value[0]).ThenBy(x => x.Value[1])) { Console.WriteLine(Value.Key); } } } }