
Module Program
    Sub Main(args As String())
        Dim sInputS As String = Console.ReadLine()
        Dim sInputT As String = Console.ReadLine()

        If sInputS.Length > 0 And 10 >= sInputS.Length Then
            If sInputT.Length = sInputS.Length + 1 Then
                If sInputT.Remove(sInputT.Length - 1, 1) = sInputS Then
                    Console.WriteLine("Yes")
                Else
                    Console.WriteLine("No")
                End If
            Else
                Console.WriteLine("No")
            End If
        Else
            Console.WriteLine("No")
        End If
    End Sub
End Module
