import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		
		int N = scanner.nextInt();
		String list[] = new String[N];
		
		for(int n = 1; n <= N; n++){
			list[n-1] = scanner.next();
		}
		
		scanner.close();
		
		for(int n = 1; n <= N; n++){
			for(int m = 1; m <= N; m++){

				if(n != m && list[n-1].equals(list[m-1])){
					System.out.println("No");
					return;
				}
			}
		}
		
		for(int n = 1; n <= N-1; n++){
			String head = list[n].substring(0,1);
			String tail = list[n-1].substring(list[n-1].length()-1);
			
			if(!head.equals(tail)){
				System.out.println("No");
				return;
			}	
		}
		
		System.out.println("Yes");
	}
} import java.util.Scanner; Scanner java.util public class Main {

	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		
		int N = scanner.nextInt();
		String list[] = new String[N];
		
		for(int n = 1; n <= N; n++){
			list[n-1] = scanner.next();
		}
		
		scanner.close();
		
		for(int n = 1; n <= N; n++){
			for(int m = 1; m <= N; m++){

				if(n != m && list[n-1].equals(list[m-1])){
					System.out.println("No");
					return;
				}
			}
		}
		
		for(int n = 1; n <= N-1; n++){
			String head = list[n].substring(0,1);
			String tail = list[n-1].substring(list[n-1].length()-1);
			
			if(!head.equals(tail)){
				System.out.println("No");
				return;
			}	
		}
		
		System.out.println("Yes");
	}
} Main public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		
		int N = scanner.nextInt();
		String list[] = new String[N];
		
		for(int n = 1; n <= N; n++){
			list[n-1] = scanner.next();
		}
		
		scanner.close();
		
		for(int n = 1; n <= N; n++){
			for(int m = 1; m <= N; m++){

				if(n != m && list[n-1].equals(list[m-1])){
					System.out.println("No");
					return;
				}
			}
		}
		
		for(int n = 1; n <= N-1; n++){
			String head = list[n].substring(0,1);
			String tail = list[n-1].substring(list[n-1].length()-1);
			
			if(!head.equals(tail)){
				System.out.println("No");
				return;
			}	
		}
		
		System.out.println("Yes");
	} main {
		Scanner scanner = new Scanner(System.in);
		
		int N = scanner.nextInt();
		String list[] = new String[N];
		
		for(int n = 1; n <= N; n++){
			list[n-1] = scanner.next();
		}
		
		scanner.close();
		
		for(int n = 1; n <= N; n++){
			for(int m = 1; m <= N; m++){

				if(n != m && list[n-1].equals(list[m-1])){
					System.out.println("No");
					return;
				}
			}
		}
		
		for(int n = 1; n <= N-1; n++){
			String head = list[n].substring(0,1);
			String tail = list[n-1].substring(list[n-1].length()-1);
			
			if(!head.equals(tail)){
				System.out.println("No");
				return;
			}	
		}
		
		System.out.println("Yes");
	} Scanner scanner = new Scanner(System.in); scanner new Scanner(System.in) int N = scanner.nextInt(); N scanner.nextInt() scanner.nextInt scanner String list[] = new String[N]; list new String[N] N for(int n = 1; n <= N; n++){
			list[n-1] = scanner.next();
		} int n = 1; int n = 1; n 1 n <= N n N n++ n++ n {
			list[n-1] = scanner.next();
		} {
			list[n-1] = scanner.next();
		} list[n-1] = scanner.next() list[n-1] list n-1 n 1 scanner.next() scanner.next scanner scanner.close() scanner.close scanner for(int n = 1; n <= N; n++){
			for(int m = 1; m <= N; m++){

				if(n != m && list[n-1].equals(list[m-1])){
					System.out.println("No");
					return;
				}
			}
		} int n = 1; int n = 1; n 1 n <= N n N n++ n++ n {
			for(int m = 1; m <= N; m++){

				if(n != m && list[n-1].equals(list[m-1])){
					System.out.println("No");
					return;
				}
			}
		} {
			for(int m = 1; m <= N; m++){

				if(n != m && list[n-1].equals(list[m-1])){
					System.out.println("No");
					return;
				}
			}
		} for(int m = 1; m <= N; m++){

				if(n != m && list[n-1].equals(list[m-1])){
					System.out.println("No");
					return;
				}
			} int m = 1; int m = 1; m 1 m <= N m N m++ m++ m {

				if(n != m && list[n-1].equals(list[m-1])){
					System.out.println("No");
					return;
				}
			} {

				if(n != m && list[n-1].equals(list[m-1])){
					System.out.println("No");
					return;
				}
			} if(n != m && list[n-1].equals(list[m-1])){
					System.out.println("No");
					return;
				} n != m && list[n-1].equals(list[m-1]) n != m n m list[n-1].equals(list[m-1]) list[n-1].equals list[n-1] list n-1 n 1 list[m-1] list m-1 m 1 {
					System.out.println("No");
					return;
				} System.out.println("No") System.out.println System.out System System.out "No" return; for(int n = 1; n <= N-1; n++){
			String head = list[n].substring(0,1);
			String tail = list[n-1].substring(list[n-1].length()-1);
			
			if(!head.equals(tail)){
				System.out.println("No");
				return;
			}	
		} int n = 1; int n = 1; n 1 n <= N-1 n N-1 N 1 n++ n++ n {
			String head = list[n].substring(0,1);
			String tail = list[n-1].substring(list[n-1].length()-1);
			
			if(!head.equals(tail)){
				System.out.println("No");
				return;
			}	
		} {
			String head = list[n].substring(0,1);
			String tail = list[n-1].substring(list[n-1].length()-1);
			
			if(!head.equals(tail)){
				System.out.println("No");
				return;
			}	
		} String head = list[n].substring(0,1); head list[n].substring(0,1) list[n].substring list[n] list n 0 1 String tail = list[n-1].substring(list[n-1].length()-1); tail list[n-1].substring(list[n-1].length()-1) list[n-1].substring list[n-1] list n-1 n 1 list[n-1].length()-1 list[n-1].length() list[n-1].length list[n-1] list n-1 n 1 1 if(!head.equals(tail)){
				System.out.println("No");
				return;
			} !head.equals(tail) head.equals(tail) head.equals head tail {
				System.out.println("No");
				return;
			} System.out.println("No") System.out.println System.out System System.out "No" return; 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 scanner = new Scanner(System.in);
		
		int N = scanner.nextInt();
		String list[] = new String[N];
		
		for(int n = 1; n <= N; n++){
			list[n-1] = scanner.next();
		}
		
		scanner.close();
		
		for(int n = 1; n <= N; n++){
			for(int m = 1; m <= N; m++){

				if(n != m && list[n-1].equals(list[m-1])){
					System.out.println("No");
					return;
				}
			}
		}
		
		for(int n = 1; n <= N-1; n++){
			String head = list[n].substring(0,1);
			String tail = list[n-1].substring(list[n-1].length()-1);
			
			if(!head.equals(tail)){
				System.out.println("No");
				return;
			}	
		}
		
		System.out.println("Yes");
	}
} public class Main {

	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		
		int N = scanner.nextInt();
		String list[] = new String[N];
		
		for(int n = 1; n <= N; n++){
			list[n-1] = scanner.next();
		}
		
		scanner.close();
		
		for(int n = 1; n <= N; n++){
			for(int m = 1; m <= N; m++){

				if(n != m && list[n-1].equals(list[m-1])){
					System.out.println("No");
					return;
				}
			}
		}
		
		for(int n = 1; n <= N-1; n++){
			String head = list[n].substring(0,1);
			String tail = list[n-1].substring(list[n-1].length()-1);
			
			if(!head.equals(tail)){
				System.out.println("No");
				return;
			}	
		}
		
		System.out.println("Yes");
	}
} Main
import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner scanner = new Scanner(System.in);
		
		int N = scanner.nextInt();
		String list[] = new String[N];
		
		for(int n = 1; n <= N; n++){
			list[n-1] = scanner.next();
		}
		
		scanner.close();
		
		for(int n = 1; n <= N; n++){
			for(int m = 1; m <= N; m++){

				if(n != m && list[n-1].equals(list[m-1])){
					System.out.println("No");
					return;
				}
			}
		}
		
		for(int n = 1; n <= N-1; n++){
			String head = list[n].substring(0,1);
			String tail = list[n-1].substring(list[n-1].length()-1);
			
			if(!head.equals(tail)){
				System.out.println("No");
				return;
			}	
		}
		
		System.out.println("Yes");
	}
}
