import java.util.Scanner;


public class Main {

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		boolean judje = true;

		Scanner scan = new Scanner(System.in);

		char[] S = scan.next().toCharArray();
		char[] T = scan.next().toCharArray();

		for(int i = 0; i < S.length; i++)
			if(S[i] != T[i])
				judje = false;

		if(T.length - S.length != 1)
			judje = false;

		System.out.println((judje ? "Yes" : "No"));
	}

} import java.util.Scanner; Scanner java.util public class Main {

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		boolean judje = true;

		Scanner scan = new Scanner(System.in);

		char[] S = scan.next().toCharArray();
		char[] T = scan.next().toCharArray();

		for(int i = 0; i < S.length; i++)
			if(S[i] != T[i])
				judje = false;

		if(T.length - S.length != 1)
			judje = false;

		System.out.println((judje ? "Yes" : "No"));
	}

} Main public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		boolean judje = true;

		Scanner scan = new Scanner(System.in);

		char[] S = scan.next().toCharArray();
		char[] T = scan.next().toCharArray();

		for(int i = 0; i < S.length; i++)
			if(S[i] != T[i])
				judje = false;

		if(T.length - S.length != 1)
			judje = false;

		System.out.println((judje ? "Yes" : "No"));
	} main {
		// TODO 自動生成されたメソッド・スタブ
		boolean judje = true;

		Scanner scan = new Scanner(System.in);

		char[] S = scan.next().toCharArray();
		char[] T = scan.next().toCharArray();

		for(int i = 0; i < S.length; i++)
			if(S[i] != T[i])
				judje = false;

		if(T.length - S.length != 1)
			judje = false;

		System.out.println((judje ? "Yes" : "No"));
	} boolean judje = true; judje true Scanner scan = new Scanner(System.in); scan new Scanner(System.in) char[] S = scan.next().toCharArray(); S scan.next().toCharArray() scan.next().toCharArray scan.next() scan.next scan char[] T = scan.next().toCharArray(); T scan.next().toCharArray() scan.next().toCharArray scan.next() scan.next scan for(int i = 0; i < S.length; i++)
			if(S[i] != T[i])
				judje = false; int i = 0; int i = 0; i 0 i < S.length i S.length S S.length i++ i++ i if(S[i] != T[i])
				judje = false; if(S[i] != T[i])
				judje = false; S[i] != T[i] S[i] S i T[i] T i judje = false judje false if(T.length - S.length != 1)
			judje = false; T.length - S.length != 1 T.length - S.length T.length T T.length S.length S S.length 1 judje = false judje false System.out.println((judje ? "Yes" : "No")) System.out.println System.out System System.out (judje ? "Yes" : "No") judje "Yes" "No" String[] args args public class Main {

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		boolean judje = true;

		Scanner scan = new Scanner(System.in);

		char[] S = scan.next().toCharArray();
		char[] T = scan.next().toCharArray();

		for(int i = 0; i < S.length; i++)
			if(S[i] != T[i])
				judje = false;

		if(T.length - S.length != 1)
			judje = false;

		System.out.println((judje ? "Yes" : "No"));
	}

} public class Main {

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		boolean judje = true;

		Scanner scan = new Scanner(System.in);

		char[] S = scan.next().toCharArray();
		char[] T = scan.next().toCharArray();

		for(int i = 0; i < S.length; i++)
			if(S[i] != T[i])
				judje = false;

		if(T.length - S.length != 1)
			judje = false;

		System.out.println((judje ? "Yes" : "No"));
	}

} Main
import java.util.Scanner;


public class Main {

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		boolean judje = true;

		Scanner scan = new Scanner(System.in);

		char[] S = scan.next().toCharArray();
		char[] T = scan.next().toCharArray();

		for(int i = 0; i < S.length; i++)
			if(S[i] != T[i])
				judje = false;

		if(T.length - S.length != 1)
			judje = false;

		System.out.println((judje ? "Yes" : "No"));
	}

}
