import java.util.Scanner;

public class Main {
	public static void main(String[] args){
			Scanner sc = new Scanner(System.in);
			String[] S = sc.next().split("");
			String[] T = sc.next().split("");
			sc.close();
			if (S.length + 1 == T.length) {
				for (int i = 0; i < S.length; i++) {
					if (! S[i].equals(T[i])){
						System.out.println("No");
						return;
					}
				}
				System.out.println("Yes");
				return;
			}
			System.out.println("No");
    }
} import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[] args){
			Scanner sc = new Scanner(System.in);
			String[] S = sc.next().split("");
			String[] T = sc.next().split("");
			sc.close();
			if (S.length + 1 == T.length) {
				for (int i = 0; i < S.length; i++) {
					if (! S[i].equals(T[i])){
						System.out.println("No");
						return;
					}
				}
				System.out.println("Yes");
				return;
			}
			System.out.println("No");
    }
} Main public static void main(String[] args){
			Scanner sc = new Scanner(System.in);
			String[] S = sc.next().split("");
			String[] T = sc.next().split("");
			sc.close();
			if (S.length + 1 == T.length) {
				for (int i = 0; i < S.length; i++) {
					if (! S[i].equals(T[i])){
						System.out.println("No");
						return;
					}
				}
				System.out.println("Yes");
				return;
			}
			System.out.println("No");
    } main {
			Scanner sc = new Scanner(System.in);
			String[] S = sc.next().split("");
			String[] T = sc.next().split("");
			sc.close();
			if (S.length + 1 == T.length) {
				for (int i = 0; i < S.length; i++) {
					if (! S[i].equals(T[i])){
						System.out.println("No");
						return;
					}
				}
				System.out.println("Yes");
				return;
			}
			System.out.println("No");
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) String[] S = sc.next().split(""); S sc.next().split("") sc.next().split sc.next() sc.next sc "" String[] T = sc.next().split(""); T sc.next().split("") sc.next().split sc.next() sc.next sc "" sc.close() sc.close sc if (S.length + 1 == T.length) {
				for (int i = 0; i < S.length; i++) {
					if (! S[i].equals(T[i])){
						System.out.println("No");
						return;
					}
				}
				System.out.println("Yes");
				return;
			} S.length + 1 == T.length S.length + 1 S.length S S.length 1 T.length T T.length {
				for (int i = 0; i < S.length; i++) {
					if (! S[i].equals(T[i])){
						System.out.println("No");
						return;
					}
				}
				System.out.println("Yes");
				return;
			} for (int i = 0; i < S.length; i++) {
					if (! S[i].equals(T[i])){
						System.out.println("No");
						return;
					}
				} int i = 0; int i = 0; i 0 i < S.length i S.length S S.length i++ i++ i {
					if (! S[i].equals(T[i])){
						System.out.println("No");
						return;
					}
				} {
					if (! S[i].equals(T[i])){
						System.out.println("No");
						return;
					}
				} if (! S[i].equals(T[i])){
						System.out.println("No");
						return;
					} ! S[i].equals(T[i]) S[i].equals(T[i]) S[i].equals S[i] S i T[i] T i {
						System.out.println("No");
						return;
					} System.out.println("No") System.out.println System.out System System.out "No" return; System.out.println("Yes") System.out.println System.out System System.out "Yes" return; System.out.println("No") System.out.println System.out System System.out "No" String[] args args public class Main {
	public static void main(String[] args){
			Scanner sc = new Scanner(System.in);
			String[] S = sc.next().split("");
			String[] T = sc.next().split("");
			sc.close();
			if (S.length + 1 == T.length) {
				for (int i = 0; i < S.length; i++) {
					if (! S[i].equals(T[i])){
						System.out.println("No");
						return;
					}
				}
				System.out.println("Yes");
				return;
			}
			System.out.println("No");
    }
} public class Main {
	public static void main(String[] args){
			Scanner sc = new Scanner(System.in);
			String[] S = sc.next().split("");
			String[] T = sc.next().split("");
			sc.close();
			if (S.length + 1 == T.length) {
				for (int i = 0; i < S.length; i++) {
					if (! S[i].equals(T[i])){
						System.out.println("No");
						return;
					}
				}
				System.out.println("Yes");
				return;
			}
			System.out.println("No");
    }
} Main
import java.util.Scanner;

public class Main {
	public static void main(String[] args){
			Scanner sc = new Scanner(System.in);
			String[] S = sc.next().split("");
			String[] T = sc.next().split("");
			sc.close();
			if (S.length + 1 == T.length) {
				for (int i = 0; i < S.length; i++) {
					if (! S[i].equals(T[i])){
						System.out.println("No");
						return;
					}
				}
				System.out.println("Yes");
				return;
			}
			System.out.println("No");
    }
}
