import java.util.*;
 
public class Main{
    public static void main(String[] args){
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        boolean boo = true;
        String words[] = new String[n];
        words[0] = sc.next();
        String str[] = words[0].split("");
        String endC = str[str.length -1];
        for(int i=1; i<n; i++){
            String s = sc.next();
            if(Arrays.asList(words).contains(s)) boo = false;
            String nowStr[] = s.split("");
            String startC = nowStr[0];
            if(!startC.equals(endC)) boo = false;
            endC = nowStr[nowStr.length -1];
            words[i] = s;
        }
        if(boo) System.out.println("Yes");
        else System.out.println("No");
    }
} import java.util.*; util.* java public class Main{
    public static void main(String[] args){
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        boolean boo = true;
        String words[] = new String[n];
        words[0] = sc.next();
        String str[] = words[0].split("");
        String endC = str[str.length -1];
        for(int i=1; i<n; i++){
            String s = sc.next();
            if(Arrays.asList(words).contains(s)) boo = false;
            String nowStr[] = s.split("");
            String startC = nowStr[0];
            if(!startC.equals(endC)) boo = false;
            endC = nowStr[nowStr.length -1];
            words[i] = s;
        }
        if(boo) System.out.println("Yes");
        else System.out.println("No");
    }
} Main public static void main(String[] args){
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        boolean boo = true;
        String words[] = new String[n];
        words[0] = sc.next();
        String str[] = words[0].split("");
        String endC = str[str.length -1];
        for(int i=1; i<n; i++){
            String s = sc.next();
            if(Arrays.asList(words).contains(s)) boo = false;
            String nowStr[] = s.split("");
            String startC = nowStr[0];
            if(!startC.equals(endC)) boo = false;
            endC = nowStr[nowStr.length -1];
            words[i] = s;
        }
        if(boo) System.out.println("Yes");
        else System.out.println("No");
    } main {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        boolean boo = true;
        String words[] = new String[n];
        words[0] = sc.next();
        String str[] = words[0].split("");
        String endC = str[str.length -1];
        for(int i=1; i<n; i++){
            String s = sc.next();
            if(Arrays.asList(words).contains(s)) boo = false;
            String nowStr[] = s.split("");
            String startC = nowStr[0];
            if(!startC.equals(endC)) boo = false;
            endC = nowStr[nowStr.length -1];
            words[i] = s;
        }
        if(boo) System.out.println("Yes");
        else System.out.println("No");
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc boolean boo = true; boo true String words[] = new String[n]; words new String[n] n words[0] = sc.next() words[0] words 0 sc.next() sc.next sc String str[] = words[0].split(""); str words[0].split("") words[0].split words[0] words 0 "" String endC = str[str.length -1]; endC str[str.length -1] str str.length -1 str.length str str.length 1 for(int i=1; i<n; i++){
            String s = sc.next();
            if(Arrays.asList(words).contains(s)) boo = false;
            String nowStr[] = s.split("");
            String startC = nowStr[0];
            if(!startC.equals(endC)) boo = false;
            endC = nowStr[nowStr.length -1];
            words[i] = s;
        } int i=1; int i=1; i 1 i<n i n i++ i++ i {
            String s = sc.next();
            if(Arrays.asList(words).contains(s)) boo = false;
            String nowStr[] = s.split("");
            String startC = nowStr[0];
            if(!startC.equals(endC)) boo = false;
            endC = nowStr[nowStr.length -1];
            words[i] = s;
        } {
            String s = sc.next();
            if(Arrays.asList(words).contains(s)) boo = false;
            String nowStr[] = s.split("");
            String startC = nowStr[0];
            if(!startC.equals(endC)) boo = false;
            endC = nowStr[nowStr.length -1];
            words[i] = s;
        } String s = sc.next(); s sc.next() sc.next sc if(Arrays.asList(words).contains(s)) boo = false; Arrays.asList(words).contains(s) Arrays.asList(words).contains Arrays.asList(words) Arrays.asList Arrays words s boo = false boo false String nowStr[] = s.split(""); nowStr s.split("") s.split s "" String startC = nowStr[0]; startC nowStr[0] nowStr 0 if(!startC.equals(endC)) boo = false; !startC.equals(endC) startC.equals(endC) startC.equals startC endC boo = false boo false endC = nowStr[nowStr.length -1] endC nowStr[nowStr.length -1] nowStr nowStr.length -1 nowStr.length nowStr nowStr.length 1 words[i] = s words[i] words i s if(boo) System.out.println("Yes");
        else System.out.println("No"); boo System.out.println("Yes") System.out.println System.out System System.out "Yes" 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);
        int n = sc.nextInt();
        boolean boo = true;
        String words[] = new String[n];
        words[0] = sc.next();
        String str[] = words[0].split("");
        String endC = str[str.length -1];
        for(int i=1; i<n; i++){
            String s = sc.next();
            if(Arrays.asList(words).contains(s)) boo = false;
            String nowStr[] = s.split("");
            String startC = nowStr[0];
            if(!startC.equals(endC)) boo = false;
            endC = nowStr[nowStr.length -1];
            words[i] = s;
        }
        if(boo) System.out.println("Yes");
        else System.out.println("No");
    }
} public class Main{
    public static void main(String[] args){
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        boolean boo = true;
        String words[] = new String[n];
        words[0] = sc.next();
        String str[] = words[0].split("");
        String endC = str[str.length -1];
        for(int i=1; i<n; i++){
            String s = sc.next();
            if(Arrays.asList(words).contains(s)) boo = false;
            String nowStr[] = s.split("");
            String startC = nowStr[0];
            if(!startC.equals(endC)) boo = false;
            endC = nowStr[nowStr.length -1];
            words[i] = s;
        }
        if(boo) System.out.println("Yes");
        else System.out.println("No");
    }
} Main
import java.util.*;
 
public class Main{
    public static void main(String[] args){
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        boolean boo = true;
        String words[] = new String[n];
        words[0] = sc.next();
        String str[] = words[0].split("");
        String endC = str[str.length -1];
        for(int i=1; i<n; i++){
            String s = sc.next();
            if(Arrays.asList(words).contains(s)) boo = false;
            String nowStr[] = s.split("");
            String startC = nowStr[0];
            if(!startC.equals(endC)) boo = false;
            endC = nowStr[nowStr.length -1];
            words[i] = s;
        }
        if(boo) System.out.println("Yes");
        else System.out.println("No");
    }
}