import java.util.HashSet;
import java.util.Scanner;
import java.util.Set;


public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		
		int N = sc.nextInt();
		Set<String> set = new HashSet<String>();
		
		char wordEnd = '0';
		for(int i = 0;  i < N; i++) {
			String s = sc.next();
			if(i != 0) {
				if(wordEnd != s.charAt(0)|| set.contains(s)) {
					System.out.println("No");
					return;
				}
			}
			wordEnd = s.charAt(s.length()-1);
			set.add(s);
		}
		System.out.println("Yes");
	}

} import java.util.HashSet; HashSet java.util import java.util.Scanner; Scanner java.util import java.util.Set; Set java.util public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		
		int N = sc.nextInt();
		Set<String> set = new HashSet<String>();
		
		char wordEnd = '0';
		for(int i = 0;  i < N; i++) {
			String s = sc.next();
			if(i != 0) {
				if(wordEnd != s.charAt(0)|| set.contains(s)) {
					System.out.println("No");
					return;
				}
			}
			wordEnd = s.charAt(s.length()-1);
			set.add(s);
		}
		System.out.println("Yes");
	}

} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		
		int N = sc.nextInt();
		Set<String> set = new HashSet<String>();
		
		char wordEnd = '0';
		for(int i = 0;  i < N; i++) {
			String s = sc.next();
			if(i != 0) {
				if(wordEnd != s.charAt(0)|| set.contains(s)) {
					System.out.println("No");
					return;
				}
			}
			wordEnd = s.charAt(s.length()-1);
			set.add(s);
		}
		System.out.println("Yes");
	} main {
		Scanner sc = new Scanner(System.in);
		
		int N = sc.nextInt();
		Set<String> set = new HashSet<String>();
		
		char wordEnd = '0';
		for(int i = 0;  i < N; i++) {
			String s = sc.next();
			if(i != 0) {
				if(wordEnd != s.charAt(0)|| set.contains(s)) {
					System.out.println("No");
					return;
				}
			}
			wordEnd = s.charAt(s.length()-1);
			set.add(s);
		}
		System.out.println("Yes");
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int N = sc.nextInt(); N sc.nextInt() sc.nextInt sc Set<String> set = new HashSet<String>(); set new HashSet<String>() char wordEnd = '0'; wordEnd '0' for(int i = 0;  i < N; i++) {
			String s = sc.next();
			if(i != 0) {
				if(wordEnd != s.charAt(0)|| set.contains(s)) {
					System.out.println("No");
					return;
				}
			}
			wordEnd = s.charAt(s.length()-1);
			set.add(s);
		} int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
			String s = sc.next();
			if(i != 0) {
				if(wordEnd != s.charAt(0)|| set.contains(s)) {
					System.out.println("No");
					return;
				}
			}
			wordEnd = s.charAt(s.length()-1);
			set.add(s);
		} {
			String s = sc.next();
			if(i != 0) {
				if(wordEnd != s.charAt(0)|| set.contains(s)) {
					System.out.println("No");
					return;
				}
			}
			wordEnd = s.charAt(s.length()-1);
			set.add(s);
		} String s = sc.next(); s sc.next() sc.next sc if(i != 0) {
				if(wordEnd != s.charAt(0)|| set.contains(s)) {
					System.out.println("No");
					return;
				}
			} i != 0 i 0 {
				if(wordEnd != s.charAt(0)|| set.contains(s)) {
					System.out.println("No");
					return;
				}
			} if(wordEnd != s.charAt(0)|| set.contains(s)) {
					System.out.println("No");
					return;
				} wordEnd != s.charAt(0)|| set.contains(s) wordEnd != s.charAt(0) wordEnd s.charAt(0) s.charAt s 0 set.contains(s) set.contains set s {
					System.out.println("No");
					return;
				} System.out.println("No") System.out.println System.out System System.out "No" return; wordEnd = s.charAt(s.length()-1) wordEnd s.charAt(s.length()-1) s.charAt s s.length()-1 s.length() s.length s 1 set.add(s) set.add set s 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 sc = new Scanner(System.in);
		
		int N = sc.nextInt();
		Set<String> set = new HashSet<String>();
		
		char wordEnd = '0';
		for(int i = 0;  i < N; i++) {
			String s = sc.next();
			if(i != 0) {
				if(wordEnd != s.charAt(0)|| set.contains(s)) {
					System.out.println("No");
					return;
				}
			}
			wordEnd = s.charAt(s.length()-1);
			set.add(s);
		}
		System.out.println("Yes");
	}

} public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		
		int N = sc.nextInt();
		Set<String> set = new HashSet<String>();
		
		char wordEnd = '0';
		for(int i = 0;  i < N; i++) {
			String s = sc.next();
			if(i != 0) {
				if(wordEnd != s.charAt(0)|| set.contains(s)) {
					System.out.println("No");
					return;
				}
			}
			wordEnd = s.charAt(s.length()-1);
			set.add(s);
		}
		System.out.println("Yes");
	}

} Main
import java.util.HashSet;
import java.util.Scanner;
import java.util.Set;


public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		
		int N = sc.nextInt();
		Set<String> set = new HashSet<String>();
		
		char wordEnd = '0';
		for(int i = 0;  i < N; i++) {
			String s = sc.next();
			if(i != 0) {
				if(wordEnd != s.charAt(0)|| set.contains(s)) {
					System.out.println("No");
					return;
				}
			}
			wordEnd = s.charAt(s.length()-1);
			set.add(s);
		}
		System.out.println("Yes");
	}

}
