import java.util.*;
 
public class Main {
	
    public static void main(String[] args) {
    	Scanner sc = new Scanner(System.in);
    	int N = sc.nextInt();
    	char save = 0;
    	String ans = "Yes";
    	Set<String> old = new HashSet<>();
    	for (int i = 0; i < N; i++) {
    		String s = sc.next();
    		if (i != 0 && (s.charAt(0) != save || old.contains(s))) {
    			ans = "No";
    			break;
    		}
    		save = s.charAt(s.length()-1);
    		old.add(s);
    	}
    	System.out.println(ans);
    }
} import java.util.*; util.* java public class Main {
	
    public static void main(String[] args) {
    	Scanner sc = new Scanner(System.in);
    	int N = sc.nextInt();
    	char save = 0;
    	String ans = "Yes";
    	Set<String> old = new HashSet<>();
    	for (int i = 0; i < N; i++) {
    		String s = sc.next();
    		if (i != 0 && (s.charAt(0) != save || old.contains(s))) {
    			ans = "No";
    			break;
    		}
    		save = s.charAt(s.length()-1);
    		old.add(s);
    	}
    	System.out.println(ans);
    }
} Main public static void main(String[] args) {
    	Scanner sc = new Scanner(System.in);
    	int N = sc.nextInt();
    	char save = 0;
    	String ans = "Yes";
    	Set<String> old = new HashSet<>();
    	for (int i = 0; i < N; i++) {
    		String s = sc.next();
    		if (i != 0 && (s.charAt(0) != save || old.contains(s))) {
    			ans = "No";
    			break;
    		}
    		save = s.charAt(s.length()-1);
    		old.add(s);
    	}
    	System.out.println(ans);
    } main {
    	Scanner sc = new Scanner(System.in);
    	int N = sc.nextInt();
    	char save = 0;
    	String ans = "Yes";
    	Set<String> old = new HashSet<>();
    	for (int i = 0; i < N; i++) {
    		String s = sc.next();
    		if (i != 0 && (s.charAt(0) != save || old.contains(s))) {
    			ans = "No";
    			break;
    		}
    		save = s.charAt(s.length()-1);
    		old.add(s);
    	}
    	System.out.println(ans);
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int N = sc.nextInt(); N sc.nextInt() sc.nextInt sc char save = 0; save 0 String ans = "Yes"; ans "Yes" Set<String> old = new HashSet<>(); old new HashSet<>() for (int i = 0; i < N; i++) {
    		String s = sc.next();
    		if (i != 0 && (s.charAt(0) != save || old.contains(s))) {
    			ans = "No";
    			break;
    		}
    		save = s.charAt(s.length()-1);
    		old.add(s);
    	} int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
    		String s = sc.next();
    		if (i != 0 && (s.charAt(0) != save || old.contains(s))) {
    			ans = "No";
    			break;
    		}
    		save = s.charAt(s.length()-1);
    		old.add(s);
    	} {
    		String s = sc.next();
    		if (i != 0 && (s.charAt(0) != save || old.contains(s))) {
    			ans = "No";
    			break;
    		}
    		save = s.charAt(s.length()-1);
    		old.add(s);
    	} String s = sc.next(); s sc.next() sc.next sc if (i != 0 && (s.charAt(0) != save || old.contains(s))) {
    			ans = "No";
    			break;
    		} i != 0 && (s.charAt(0) != save || old.contains(s)) i != 0 i 0 (s.charAt(0) != save || old.contains(s)) s.charAt(0) != save s.charAt(0) s.charAt s 0 save old.contains(s) old.contains old s {
    			ans = "No";
    			break;
    		} ans = "No" ans "No" break; save = s.charAt(s.length()-1) save s.charAt(s.length()-1) s.charAt s s.length()-1 s.length() s.length s 1 old.add(s) old.add old s System.out.println(ans) System.out.println System.out System System.out ans String[] args args public class Main {
	
    public static void main(String[] args) {
    	Scanner sc = new Scanner(System.in);
    	int N = sc.nextInt();
    	char save = 0;
    	String ans = "Yes";
    	Set<String> old = new HashSet<>();
    	for (int i = 0; i < N; i++) {
    		String s = sc.next();
    		if (i != 0 && (s.charAt(0) != save || old.contains(s))) {
    			ans = "No";
    			break;
    		}
    		save = s.charAt(s.length()-1);
    		old.add(s);
    	}
    	System.out.println(ans);
    }
} public class Main {
	
    public static void main(String[] args) {
    	Scanner sc = new Scanner(System.in);
    	int N = sc.nextInt();
    	char save = 0;
    	String ans = "Yes";
    	Set<String> old = new HashSet<>();
    	for (int i = 0; i < N; i++) {
    		String s = sc.next();
    		if (i != 0 && (s.charAt(0) != save || old.contains(s))) {
    			ans = "No";
    			break;
    		}
    		save = s.charAt(s.length()-1);
    		old.add(s);
    	}
    	System.out.println(ans);
    }
} Main
import java.util.*;
 
public class Main {
	
    public static void main(String[] args) {
    	Scanner sc = new Scanner(System.in);
    	int N = sc.nextInt();
    	char save = 0;
    	String ans = "Yes";
    	Set<String> old = new HashSet<>();
    	for (int i = 0; i < N; i++) {
    		String s = sc.next();
    		if (i != 0 && (s.charAt(0) != save || old.contains(s))) {
    			ans = "No";
    			break;
    		}
    		save = s.charAt(s.length()-1);
    		old.add(s);
    	}
    	System.out.println(ans);
    }
}