import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner scan = new Scanner(System.in);
        int I = scan.nextInt();
        String tmp;
        boolean b = true;
        String[] s = new String[100];
        s[0] = scan.next();
        tmp = s[0].substring(s[0].length() - 1);
        for (int i = 1; i < I; i++) {
            s[i] = scan.next();
            for (int j = 0; j < i; j++) {
                if (s[i].equals(s[j])) {
                    b = false;
                    break;
                }
            }
            if (!s[i].startsWith(tmp)) {
                b = false;
                break;
            }
            tmp = s[i].substring(s[i].length() - 1);
        }
        if(b == false){
                System.out.println("No");
                System.exit(0);
        }
        System.out.println("Yes");
    }
} import java.util.Scanner; Scanner java.util public class Main {
    public static void main(String[] args) {
        Scanner scan = new Scanner(System.in);
        int I = scan.nextInt();
        String tmp;
        boolean b = true;
        String[] s = new String[100];
        s[0] = scan.next();
        tmp = s[0].substring(s[0].length() - 1);
        for (int i = 1; i < I; i++) {
            s[i] = scan.next();
            for (int j = 0; j < i; j++) {
                if (s[i].equals(s[j])) {
                    b = false;
                    break;
                }
            }
            if (!s[i].startsWith(tmp)) {
                b = false;
                break;
            }
            tmp = s[i].substring(s[i].length() - 1);
        }
        if(b == false){
                System.out.println("No");
                System.exit(0);
        }
        System.out.println("Yes");
    }
} Main public static void main(String[] args) {
        Scanner scan = new Scanner(System.in);
        int I = scan.nextInt();
        String tmp;
        boolean b = true;
        String[] s = new String[100];
        s[0] = scan.next();
        tmp = s[0].substring(s[0].length() - 1);
        for (int i = 1; i < I; i++) {
            s[i] = scan.next();
            for (int j = 0; j < i; j++) {
                if (s[i].equals(s[j])) {
                    b = false;
                    break;
                }
            }
            if (!s[i].startsWith(tmp)) {
                b = false;
                break;
            }
            tmp = s[i].substring(s[i].length() - 1);
        }
        if(b == false){
                System.out.println("No");
                System.exit(0);
        }
        System.out.println("Yes");
    } main {
        Scanner scan = new Scanner(System.in);
        int I = scan.nextInt();
        String tmp;
        boolean b = true;
        String[] s = new String[100];
        s[0] = scan.next();
        tmp = s[0].substring(s[0].length() - 1);
        for (int i = 1; i < I; i++) {
            s[i] = scan.next();
            for (int j = 0; j < i; j++) {
                if (s[i].equals(s[j])) {
                    b = false;
                    break;
                }
            }
            if (!s[i].startsWith(tmp)) {
                b = false;
                break;
            }
            tmp = s[i].substring(s[i].length() - 1);
        }
        if(b == false){
                System.out.println("No");
                System.exit(0);
        }
        System.out.println("Yes");
    } Scanner scan = new Scanner(System.in); scan new Scanner(System.in) int I = scan.nextInt(); I scan.nextInt() scan.nextInt scan String tmp; tmp boolean b = true; b true String[] s = new String[100]; s new String[100] 100 s[0] = scan.next() s[0] s 0 scan.next() scan.next scan tmp = s[0].substring(s[0].length() - 1) tmp s[0].substring(s[0].length() - 1) s[0].substring s[0] s 0 s[0].length() - 1 s[0].length() s[0].length s[0] s 0 1 for (int i = 1; i < I; i++) {
            s[i] = scan.next();
            for (int j = 0; j < i; j++) {
                if (s[i].equals(s[j])) {
                    b = false;
                    break;
                }
            }
            if (!s[i].startsWith(tmp)) {
                b = false;
                break;
            }
            tmp = s[i].substring(s[i].length() - 1);
        } int i = 1; int i = 1; i 1 i < I i I i++ i++ i {
            s[i] = scan.next();
            for (int j = 0; j < i; j++) {
                if (s[i].equals(s[j])) {
                    b = false;
                    break;
                }
            }
            if (!s[i].startsWith(tmp)) {
                b = false;
                break;
            }
            tmp = s[i].substring(s[i].length() - 1);
        } {
            s[i] = scan.next();
            for (int j = 0; j < i; j++) {
                if (s[i].equals(s[j])) {
                    b = false;
                    break;
                }
            }
            if (!s[i].startsWith(tmp)) {
                b = false;
                break;
            }
            tmp = s[i].substring(s[i].length() - 1);
        } s[i] = scan.next() s[i] s i scan.next() scan.next scan for (int j = 0; j < i; j++) {
                if (s[i].equals(s[j])) {
                    b = false;
                    break;
                }
            } int j = 0; int j = 0; j 0 j < i j i j++ j++ j {
                if (s[i].equals(s[j])) {
                    b = false;
                    break;
                }
            } {
                if (s[i].equals(s[j])) {
                    b = false;
                    break;
                }
            } if (s[i].equals(s[j])) {
                    b = false;
                    break;
                } s[i].equals(s[j]) s[i].equals s[i] s i s[j] s j {
                    b = false;
                    break;
                } b = false b false break; if (!s[i].startsWith(tmp)) {
                b = false;
                break;
            } !s[i].startsWith(tmp) s[i].startsWith(tmp) s[i].startsWith s[i] s i tmp {
                b = false;
                break;
            } b = false b false break; tmp = s[i].substring(s[i].length() - 1) tmp s[i].substring(s[i].length() - 1) s[i].substring s[i] s i s[i].length() - 1 s[i].length() s[i].length s[i] s i 1 if(b == false){
                System.out.println("No");
                System.exit(0);
        } b == false b false {
                System.out.println("No");
                System.exit(0);
        } System.out.println("No") System.out.println System.out System System.out "No" System.exit(0) System.exit System 0 System.out.println("Yes") System.out.println System.out System System.out "Yes" String[] args args public class Main {
    public static void main(String[] args) {
        Scanner scan = new Scanner(System.in);
        int I = scan.nextInt();
        String tmp;
        boolean b = true;
        String[] s = new String[100];
        s[0] = scan.next();
        tmp = s[0].substring(s[0].length() - 1);
        for (int i = 1; i < I; i++) {
            s[i] = scan.next();
            for (int j = 0; j < i; j++) {
                if (s[i].equals(s[j])) {
                    b = false;
                    break;
                }
            }
            if (!s[i].startsWith(tmp)) {
                b = false;
                break;
            }
            tmp = s[i].substring(s[i].length() - 1);
        }
        if(b == false){
                System.out.println("No");
                System.exit(0);
        }
        System.out.println("Yes");
    }
} public class Main {
    public static void main(String[] args) {
        Scanner scan = new Scanner(System.in);
        int I = scan.nextInt();
        String tmp;
        boolean b = true;
        String[] s = new String[100];
        s[0] = scan.next();
        tmp = s[0].substring(s[0].length() - 1);
        for (int i = 1; i < I; i++) {
            s[i] = scan.next();
            for (int j = 0; j < i; j++) {
                if (s[i].equals(s[j])) {
                    b = false;
                    break;
                }
            }
            if (!s[i].startsWith(tmp)) {
                b = false;
                break;
            }
            tmp = s[i].substring(s[i].length() - 1);
        }
        if(b == false){
                System.out.println("No");
                System.exit(0);
        }
        System.out.println("Yes");
    }
} Main
import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner scan = new Scanner(System.in);
        int I = scan.nextInt();
        String tmp;
        boolean b = true;
        String[] s = new String[100];
        s[0] = scan.next();
        tmp = s[0].substring(s[0].length() - 1);
        for (int i = 1; i < I; i++) {
            s[i] = scan.next();
            for (int j = 0; j < i; j++) {
                if (s[i].equals(s[j])) {
                    b = false;
                    break;
                }
            }
            if (!s[i].startsWith(tmp)) {
                b = false;
                break;
            }
            tmp = s[i].substring(s[i].length() - 1);
        }
        if(b == false){
                System.out.println("No");
                System.exit(0);
        }
        System.out.println("Yes");
    }
}