
import java.io.BufferedInputStream;
import java.io.IOException;
import java.util.Scanner;

public class Main {
    public static void main(String[] args) throws IOException {
        Scanner sc = new Scanner(new BufferedInputStream(System.in));
        String s = sc.next();
        String t = sc.next();
        System.out.println(t.startsWith(s)&&t.length() == s.length()+1?"Yes":"No");
    }
} import java.io.BufferedInputStream; BufferedInputStream java.io import java.io.IOException; IOException java.io import java.util.Scanner; Scanner java.util public class Main {
    public static void main(String[] args) throws IOException {
        Scanner sc = new Scanner(new BufferedInputStream(System.in));
        String s = sc.next();
        String t = sc.next();
        System.out.println(t.startsWith(s)&&t.length() == s.length()+1?"Yes":"No");
    }
} Main public static void main(String[] args) throws IOException {
        Scanner sc = new Scanner(new BufferedInputStream(System.in));
        String s = sc.next();
        String t = sc.next();
        System.out.println(t.startsWith(s)&&t.length() == s.length()+1?"Yes":"No");
    } main {
        Scanner sc = new Scanner(new BufferedInputStream(System.in));
        String s = sc.next();
        String t = sc.next();
        System.out.println(t.startsWith(s)&&t.length() == s.length()+1?"Yes":"No");
    } Scanner sc = new Scanner(new BufferedInputStream(System.in)); sc new Scanner(new BufferedInputStream(System.in)) String s = sc.next(); s sc.next() sc.next sc String t = sc.next(); t sc.next() sc.next sc System.out.println(t.startsWith(s)&&t.length() == s.length()+1?"Yes":"No") System.out.println System.out System System.out t.startsWith(s)&&t.length() == s.length()+1?"Yes":"No" t.startsWith(s)&&t.length() == s.length()+1 t.startsWith(s) t.startsWith t s t.length() == s.length()+1 t.length() t.length t s.length()+1 s.length() s.length s 1 "Yes" "No" String[] args args public class Main {
    public static void main(String[] args) throws IOException {
        Scanner sc = new Scanner(new BufferedInputStream(System.in));
        String s = sc.next();
        String t = sc.next();
        System.out.println(t.startsWith(s)&&t.length() == s.length()+1?"Yes":"No");
    }
} public class Main {
    public static void main(String[] args) throws IOException {
        Scanner sc = new Scanner(new BufferedInputStream(System.in));
        String s = sc.next();
        String t = sc.next();
        System.out.println(t.startsWith(s)&&t.length() == s.length()+1?"Yes":"No");
    }
} Main

import java.io.BufferedInputStream;
import java.io.IOException;
import java.util.Scanner;

public class Main {
    public static void main(String[] args) throws IOException {
        Scanner sc = new Scanner(new BufferedInputStream(System.in));
        String s = sc.next();
        String t = sc.next();
        System.out.println(t.startsWith(s)&&t.length() == s.length()+1?"Yes":"No");
    }
}
