import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.ArrayList;
import java.util.List;

//Atcoder用


/*
 * BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		String[] abc = br.readLine().split(" ");
		int a = Integer.parseInt(abc[0]);
		int b = Integer.parseInt(abc[1]);
		int c = Integer.parseInt(abc[2]);
 */
public class Main {
	public static void main(String[] args)throws IOException{
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		int N = Integer.parseInt(br.readLine());
		List<String> sir = new ArrayList<String>();
		boolean isCorrect = true;
		String lastWord="";
		for(int n=0;n<N;n++){
			String word = br.readLine();
			String[] chr = word.split("");

			if(n==0)lastWord = chr[chr.length-1];
			else{
				if(!lastWord.equals(chr[0])){
					isCorrect = false;
					//System.out.println("lastword");
					break;
				}else{
					if(sir.contains(word)){
						isCorrect = false;
						//System.out.println("sameword");
						break;
					}
					sir.add(word);
					lastWord = chr[chr.length-1];
				}
			}

			sir.add(word);
		}
		if(isCorrect)System.out.println("Yes");
		else System.out.println("No");


	}

} import java.io.BufferedReader; BufferedReader java.io import java.io.IOException; IOException java.io import java.io.InputStreamReader; InputStreamReader java.io import java.util.ArrayList; ArrayList java.util import java.util.List; List java.util public class Main {
	public static void main(String[] args)throws IOException{
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		int N = Integer.parseInt(br.readLine());
		List<String> sir = new ArrayList<String>();
		boolean isCorrect = true;
		String lastWord="";
		for(int n=0;n<N;n++){
			String word = br.readLine();
			String[] chr = word.split("");

			if(n==0)lastWord = chr[chr.length-1];
			else{
				if(!lastWord.equals(chr[0])){
					isCorrect = false;
					//System.out.println("lastword");
					break;
				}else{
					if(sir.contains(word)){
						isCorrect = false;
						//System.out.println("sameword");
						break;
					}
					sir.add(word);
					lastWord = chr[chr.length-1];
				}
			}

			sir.add(word);
		}
		if(isCorrect)System.out.println("Yes");
		else System.out.println("No");


	}

} Main public static void main(String[] args)throws IOException{
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		int N = Integer.parseInt(br.readLine());
		List<String> sir = new ArrayList<String>();
		boolean isCorrect = true;
		String lastWord="";
		for(int n=0;n<N;n++){
			String word = br.readLine();
			String[] chr = word.split("");

			if(n==0)lastWord = chr[chr.length-1];
			else{
				if(!lastWord.equals(chr[0])){
					isCorrect = false;
					//System.out.println("lastword");
					break;
				}else{
					if(sir.contains(word)){
						isCorrect = false;
						//System.out.println("sameword");
						break;
					}
					sir.add(word);
					lastWord = chr[chr.length-1];
				}
			}

			sir.add(word);
		}
		if(isCorrect)System.out.println("Yes");
		else System.out.println("No");


	} main {
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		int N = Integer.parseInt(br.readLine());
		List<String> sir = new ArrayList<String>();
		boolean isCorrect = true;
		String lastWord="";
		for(int n=0;n<N;n++){
			String word = br.readLine();
			String[] chr = word.split("");

			if(n==0)lastWord = chr[chr.length-1];
			else{
				if(!lastWord.equals(chr[0])){
					isCorrect = false;
					//System.out.println("lastword");
					break;
				}else{
					if(sir.contains(word)){
						isCorrect = false;
						//System.out.println("sameword");
						break;
					}
					sir.add(word);
					lastWord = chr[chr.length-1];
				}
			}

			sir.add(word);
		}
		if(isCorrect)System.out.println("Yes");
		else System.out.println("No");


	} 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 List<String> sir = new ArrayList<String>(); sir new ArrayList<String>() boolean isCorrect = true; isCorrect true String lastWord=""; lastWord "" for(int n=0;n<N;n++){
			String word = br.readLine();
			String[] chr = word.split("");

			if(n==0)lastWord = chr[chr.length-1];
			else{
				if(!lastWord.equals(chr[0])){
					isCorrect = false;
					//System.out.println("lastword");
					break;
				}else{
					if(sir.contains(word)){
						isCorrect = false;
						//System.out.println("sameword");
						break;
					}
					sir.add(word);
					lastWord = chr[chr.length-1];
				}
			}

			sir.add(word);
		} int n=0; int n=0; n 0 n<N n N n++ n++ n {
			String word = br.readLine();
			String[] chr = word.split("");

			if(n==0)lastWord = chr[chr.length-1];
			else{
				if(!lastWord.equals(chr[0])){
					isCorrect = false;
					//System.out.println("lastword");
					break;
				}else{
					if(sir.contains(word)){
						isCorrect = false;
						//System.out.println("sameword");
						break;
					}
					sir.add(word);
					lastWord = chr[chr.length-1];
				}
			}

			sir.add(word);
		} {
			String word = br.readLine();
			String[] chr = word.split("");

			if(n==0)lastWord = chr[chr.length-1];
			else{
				if(!lastWord.equals(chr[0])){
					isCorrect = false;
					//System.out.println("lastword");
					break;
				}else{
					if(sir.contains(word)){
						isCorrect = false;
						//System.out.println("sameword");
						break;
					}
					sir.add(word);
					lastWord = chr[chr.length-1];
				}
			}

			sir.add(word);
		} String word = br.readLine(); word br.readLine() br.readLine br String[] chr = word.split(""); chr word.split("") word.split word "" if(n==0)lastWord = chr[chr.length-1];
			else{
				if(!lastWord.equals(chr[0])){
					isCorrect = false;
					//System.out.println("lastword");
					break;
				}else{
					if(sir.contains(word)){
						isCorrect = false;
						//System.out.println("sameword");
						break;
					}
					sir.add(word);
					lastWord = chr[chr.length-1];
				}
			} n==0 n 0 lastWord = chr[chr.length-1] lastWord chr[chr.length-1] chr chr.length-1 chr.length chr chr.length 1 {
				if(!lastWord.equals(chr[0])){
					isCorrect = false;
					//System.out.println("lastword");
					break;
				}else{
					if(sir.contains(word)){
						isCorrect = false;
						//System.out.println("sameword");
						break;
					}
					sir.add(word);
					lastWord = chr[chr.length-1];
				}
			} if(!lastWord.equals(chr[0])){
					isCorrect = false;
					//System.out.println("lastword");
					break;
				}else{
					if(sir.contains(word)){
						isCorrect = false;
						//System.out.println("sameword");
						break;
					}
					sir.add(word);
					lastWord = chr[chr.length-1];
				} !lastWord.equals(chr[0]) lastWord.equals(chr[0]) lastWord.equals lastWord chr[0] chr 0 {
					isCorrect = false;
					//System.out.println("lastword");
					break;
				} isCorrect = false isCorrect false break; {
					if(sir.contains(word)){
						isCorrect = false;
						//System.out.println("sameword");
						break;
					}
					sir.add(word);
					lastWord = chr[chr.length-1];
				} if(sir.contains(word)){
						isCorrect = false;
						//System.out.println("sameword");
						break;
					} sir.contains(word) sir.contains sir word {
						isCorrect = false;
						//System.out.println("sameword");
						break;
					} isCorrect = false isCorrect false break; sir.add(word) sir.add sir word lastWord = chr[chr.length-1] lastWord chr[chr.length-1] chr chr.length-1 chr.length chr chr.length 1 sir.add(word) sir.add sir word if(isCorrect)System.out.println("Yes");
		else System.out.println("No"); isCorrect 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)throws IOException{
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		int N = Integer.parseInt(br.readLine());
		List<String> sir = new ArrayList<String>();
		boolean isCorrect = true;
		String lastWord="";
		for(int n=0;n<N;n++){
			String word = br.readLine();
			String[] chr = word.split("");

			if(n==0)lastWord = chr[chr.length-1];
			else{
				if(!lastWord.equals(chr[0])){
					isCorrect = false;
					//System.out.println("lastword");
					break;
				}else{
					if(sir.contains(word)){
						isCorrect = false;
						//System.out.println("sameword");
						break;
					}
					sir.add(word);
					lastWord = chr[chr.length-1];
				}
			}

			sir.add(word);
		}
		if(isCorrect)System.out.println("Yes");
		else System.out.println("No");


	}

} public class Main {
	public static void main(String[] args)throws IOException{
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		int N = Integer.parseInt(br.readLine());
		List<String> sir = new ArrayList<String>();
		boolean isCorrect = true;
		String lastWord="";
		for(int n=0;n<N;n++){
			String word = br.readLine();
			String[] chr = word.split("");

			if(n==0)lastWord = chr[chr.length-1];
			else{
				if(!lastWord.equals(chr[0])){
					isCorrect = false;
					//System.out.println("lastword");
					break;
				}else{
					if(sir.contains(word)){
						isCorrect = false;
						//System.out.println("sameword");
						break;
					}
					sir.add(word);
					lastWord = chr[chr.length-1];
				}
			}

			sir.add(word);
		}
		if(isCorrect)System.out.println("Yes");
		else System.out.println("No");


	}

} Main
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.ArrayList;
import java.util.List;

//Atcoder用


/*
 * BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		String[] abc = br.readLine().split(" ");
		int a = Integer.parseInt(abc[0]);
		int b = Integer.parseInt(abc[1]);
		int c = Integer.parseInt(abc[2]);
 */
public class Main {
	public static void main(String[] args)throws IOException{
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		int N = Integer.parseInt(br.readLine());
		List<String> sir = new ArrayList<String>();
		boolean isCorrect = true;
		String lastWord="";
		for(int n=0;n<N;n++){
			String word = br.readLine();
			String[] chr = word.split("");

			if(n==0)lastWord = chr[chr.length-1];
			else{
				if(!lastWord.equals(chr[0])){
					isCorrect = false;
					//System.out.println("lastword");
					break;
				}else{
					if(sir.contains(word)){
						isCorrect = false;
						//System.out.println("sameword");
						break;
					}
					sir.add(word);
					lastWord = chr[chr.length-1];
				}
			}

			sir.add(word);
		}
		if(isCorrect)System.out.println("Yes");
		else System.out.println("No");


	}

}