using System.Linq; using System.Collections.Generic; using System; public class Hello { public static void Main() { var d = new Dictionary(); var s = Console.ReadLine().Trim(); for (int i = 0; i < 13; i++) if (d.ContainsKey(s[i])) d[s[i]]++; else d[s[i]] = 1; Console.WriteLine(getAns(d)); } public static string getAns (Dictionary d) { var ng = "Impossible"; if (d.Count() != 7) return ng; var a = d.Count(x => x.Value == 1); if (a == 1) foreach (var x in d) if (x.Value == 1) return x.Key.ToString(); return ng; } }