import java.util.*;
import java.io.*;
public class Main {
    public static void main(String[] args) throws Exception {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        int N = Integer.parseInt(br.readLine());
        
        Shiritori shiritori = new Shiritori();
        for(int i= 0; i< N; i++){
            String word = br.readLine();
            if(!(shiritori.isRightInitial(word) && shiritori.isNotContains(word))){
                System.out.println("No");
                return;
            }
            shiritori.accepted(word);
        }
        System.out.println("Yes");
    }
}
class Shiritori{
    private List<String> wordList;
    public Shiritori(){
        this.wordList = new ArrayList<String>();
    }
    public boolean isRightInitial(String nextword){
        if(this.wordList.size() == 0) return true;
        String lastword = this.wordList.get(this.wordList.size() - 1);
        String head = nextword.substring(0, 1);
        String butt = lastword.substring(lastword.length() - 1, lastword.length());
        return head.equals(butt);
    }
    public boolean isNotContains(String nextword){
        return !(this.wordList.contains(nextword));
    }
    public boolean accepted(String nextword){
        this.wordList.add(nextword);
        return true;
    }
} import java.util.*; util.* java import java.io.*; io.* java public class Main {
    public static void main(String[] args) throws Exception {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        int N = Integer.parseInt(br.readLine());
        
        Shiritori shiritori = new Shiritori();
        for(int i= 0; i< N; i++){
            String word = br.readLine();
            if(!(shiritori.isRightInitial(word) && shiritori.isNotContains(word))){
                System.out.println("No");
                return;
            }
            shiritori.accepted(word);
        }
        System.out.println("Yes");
    }
} Main public static void main(String[] args) throws Exception {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        int N = Integer.parseInt(br.readLine());
        
        Shiritori shiritori = new Shiritori();
        for(int i= 0; i< N; i++){
            String word = br.readLine();
            if(!(shiritori.isRightInitial(word) && shiritori.isNotContains(word))){
                System.out.println("No");
                return;
            }
            shiritori.accepted(word);
        }
        System.out.println("Yes");
    } main {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        int N = Integer.parseInt(br.readLine());
        
        Shiritori shiritori = new Shiritori();
        for(int i= 0; i< N; i++){
            String word = br.readLine();
            if(!(shiritori.isRightInitial(word) && shiritori.isNotContains(word))){
                System.out.println("No");
                return;
            }
            shiritori.accepted(word);
        }
        System.out.println("Yes");
    } BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); br new BufferedReader(new InputStreamReader(System.in)) int N = Integer.parseInt(br.readLine()); N Integer.parseInt(br.readLine()) Integer.parseInt Integer br.readLine() br.readLine br Shiritori shiritori = new Shiritori(); shiritori new Shiritori() for(int i= 0; i< N; i++){
            String word = br.readLine();
            if(!(shiritori.isRightInitial(word) && shiritori.isNotContains(word))){
                System.out.println("No");
                return;
            }
            shiritori.accepted(word);
        } int i= 0; int i= 0; i 0 i< N i N i++ i++ i {
            String word = br.readLine();
            if(!(shiritori.isRightInitial(word) && shiritori.isNotContains(word))){
                System.out.println("No");
                return;
            }
            shiritori.accepted(word);
        } {
            String word = br.readLine();
            if(!(shiritori.isRightInitial(word) && shiritori.isNotContains(word))){
                System.out.println("No");
                return;
            }
            shiritori.accepted(word);
        } String word = br.readLine(); word br.readLine() br.readLine br if(!(shiritori.isRightInitial(word) && shiritori.isNotContains(word))){
                System.out.println("No");
                return;
            } !(shiritori.isRightInitial(word) && shiritori.isNotContains(word)) (shiritori.isRightInitial(word) && shiritori.isNotContains(word)) shiritori.isRightInitial(word) shiritori.isRightInitial shiritori word shiritori.isNotContains(word) shiritori.isNotContains shiritori word {
                System.out.println("No");
                return;
            } System.out.println("No") System.out.println System.out System System.out "No" return; shiritori.accepted(word) shiritori.accepted shiritori word System.out.println("Yes") System.out.println System.out System System.out "Yes" String[] args args class Shiritori{
    private List<String> wordList;
    public Shiritori(){
        this.wordList = new ArrayList<String>();
    }
    public boolean isRightInitial(String nextword){
        if(this.wordList.size() == 0) return true;
        String lastword = this.wordList.get(this.wordList.size() - 1);
        String head = nextword.substring(0, 1);
        String butt = lastword.substring(lastword.length() - 1, lastword.length());
        return head.equals(butt);
    }
    public boolean isNotContains(String nextword){
        return !(this.wordList.contains(nextword));
    }
    public boolean accepted(String nextword){
        this.wordList.add(nextword);
        return true;
    }
} Shiritori private List<String> wordList; wordList public Shiritori(){
        this.wordList = new ArrayList<String>();
    } Shiritori {
        this.wordList = new ArrayList<String>();
    } this.wordList = new ArrayList<String>() this.wordList this this.wordList new ArrayList<String>() public boolean isRightInitial(String nextword){
        if(this.wordList.size() == 0) return true;
        String lastword = this.wordList.get(this.wordList.size() - 1);
        String head = nextword.substring(0, 1);
        String butt = lastword.substring(lastword.length() - 1, lastword.length());
        return head.equals(butt);
    } isRightInitial {
        if(this.wordList.size() == 0) return true;
        String lastword = this.wordList.get(this.wordList.size() - 1);
        String head = nextword.substring(0, 1);
        String butt = lastword.substring(lastword.length() - 1, lastword.length());
        return head.equals(butt);
    } if(this.wordList.size() == 0) return true; this.wordList.size() == 0 this.wordList.size() this.wordList.size this.wordList this this.wordList 0 return true; true String lastword = this.wordList.get(this.wordList.size() - 1); lastword this.wordList.get(this.wordList.size() - 1) this.wordList.get this.wordList this this.wordList this.wordList.size() - 1 this.wordList.size() this.wordList.size this.wordList this this.wordList 1 String head = nextword.substring(0, 1); head nextword.substring(0, 1) nextword.substring nextword 0 1 String butt = lastword.substring(lastword.length() - 1, lastword.length()); butt lastword.substring(lastword.length() - 1, lastword.length()) lastword.substring lastword lastword.length() - 1 lastword.length() lastword.length lastword 1 lastword.length() lastword.length lastword return head.equals(butt); head.equals(butt) head.equals head butt String nextword nextword public boolean isNotContains(String nextword){
        return !(this.wordList.contains(nextword));
    } isNotContains {
        return !(this.wordList.contains(nextword));
    } return !(this.wordList.contains(nextword)); !(this.wordList.contains(nextword)) (this.wordList.contains(nextword)) this.wordList.contains this.wordList this this.wordList nextword String nextword nextword public boolean accepted(String nextword){
        this.wordList.add(nextword);
        return true;
    } accepted {
        this.wordList.add(nextword);
        return true;
    } this.wordList.add(nextword) this.wordList.add this.wordList this this.wordList nextword return true; true String nextword nextword public class Main {
    public static void main(String[] args) throws Exception {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        int N = Integer.parseInt(br.readLine());
        
        Shiritori shiritori = new Shiritori();
        for(int i= 0; i< N; i++){
            String word = br.readLine();
            if(!(shiritori.isRightInitial(word) && shiritori.isNotContains(word))){
                System.out.println("No");
                return;
            }
            shiritori.accepted(word);
        }
        System.out.println("Yes");
    }
} public class Main {
    public static void main(String[] args) throws Exception {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        int N = Integer.parseInt(br.readLine());
        
        Shiritori shiritori = new Shiritori();
        for(int i= 0; i< N; i++){
            String word = br.readLine();
            if(!(shiritori.isRightInitial(word) && shiritori.isNotContains(word))){
                System.out.println("No");
                return;
            }
            shiritori.accepted(word);
        }
        System.out.println("Yes");
    }
} Main
import java.util.*;
import java.io.*;
public class Main {
    public static void main(String[] args) throws Exception {
        BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
        int N = Integer.parseInt(br.readLine());
        
        Shiritori shiritori = new Shiritori();
        for(int i= 0; i< N; i++){
            String word = br.readLine();
            if(!(shiritori.isRightInitial(word) && shiritori.isNotContains(word))){
                System.out.println("No");
                return;
            }
            shiritori.accepted(word);
        }
        System.out.println("Yes");
    }
}
class Shiritori{
    private List<String> wordList;
    public Shiritori(){
        this.wordList = new ArrayList<String>();
    }
    public boolean isRightInitial(String nextword){
        if(this.wordList.size() == 0) return true;
        String lastword = this.wordList.get(this.wordList.size() - 1);
        String head = nextword.substring(0, 1);
        String butt = lastword.substring(lastword.length() - 1, lastword.length());
        return head.equals(butt);
    }
    public boolean isNotContains(String nextword){
        return !(this.wordList.contains(nextword));
    }
    public boolean accepted(String nextword){
        this.wordList.add(nextword);
        return true;
    }
}