class Program { static void Main(string[] args) { string topWord = Console.ReadLine()!; string bottomWord = Console.ReadLine()!; int count = 0; foreach (char top in topWord) { foreach (char bottom in bottomWord) { if (top == bottom) { count++; break; } } bottomWord = bottomWord.Remove(0, 1); } if (count == topWord.Length) { Console.WriteLine("Yes"); } else { Console.WriteLine("No"); } } }