import java.util.ArrayList;
import java.util.List;
import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		List<String> wordList = new ArrayList<String>();
		String beforeWord = sc.next();
		wordList.add(beforeWord);
		for(int i =1;i <n;i++) {
			String word = sc.next();
			if(!beforeWord.substring(beforeWord.length()-1).equals(
					word.substring(0, 1))) {
				System.out.println("No");
				return;
			}
			if(wordList.indexOf(word) != -1) {
				System.out.println("No");
				return;
			}
			wordList.add(word);
			beforeWord = word;
		}
		System.out.println("Yes");
	}
} import java.util.ArrayList; ArrayList java.util import java.util.List; List java.util import java.util.Scanner; Scanner java.util public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		List<String> wordList = new ArrayList<String>();
		String beforeWord = sc.next();
		wordList.add(beforeWord);
		for(int i =1;i <n;i++) {
			String word = sc.next();
			if(!beforeWord.substring(beforeWord.length()-1).equals(
					word.substring(0, 1))) {
				System.out.println("No");
				return;
			}
			if(wordList.indexOf(word) != -1) {
				System.out.println("No");
				return;
			}
			wordList.add(word);
			beforeWord = word;
		}
		System.out.println("Yes");
	}
} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		List<String> wordList = new ArrayList<String>();
		String beforeWord = sc.next();
		wordList.add(beforeWord);
		for(int i =1;i <n;i++) {
			String word = sc.next();
			if(!beforeWord.substring(beforeWord.length()-1).equals(
					word.substring(0, 1))) {
				System.out.println("No");
				return;
			}
			if(wordList.indexOf(word) != -1) {
				System.out.println("No");
				return;
			}
			wordList.add(word);
			beforeWord = word;
		}
		System.out.println("Yes");
	} main {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		List<String> wordList = new ArrayList<String>();
		String beforeWord = sc.next();
		wordList.add(beforeWord);
		for(int i =1;i <n;i++) {
			String word = sc.next();
			if(!beforeWord.substring(beforeWord.length()-1).equals(
					word.substring(0, 1))) {
				System.out.println("No");
				return;
			}
			if(wordList.indexOf(word) != -1) {
				System.out.println("No");
				return;
			}
			wordList.add(word);
			beforeWord = word;
		}
		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 List<String> wordList = new ArrayList<String>(); wordList new ArrayList<String>() String beforeWord = sc.next(); beforeWord sc.next() sc.next sc wordList.add(beforeWord) wordList.add wordList beforeWord for(int i =1;i <n;i++) {
			String word = sc.next();
			if(!beforeWord.substring(beforeWord.length()-1).equals(
					word.substring(0, 1))) {
				System.out.println("No");
				return;
			}
			if(wordList.indexOf(word) != -1) {
				System.out.println("No");
				return;
			}
			wordList.add(word);
			beforeWord = word;
		} int i =1; int i =1; i 1 i <n i n i++ i++ i {
			String word = sc.next();
			if(!beforeWord.substring(beforeWord.length()-1).equals(
					word.substring(0, 1))) {
				System.out.println("No");
				return;
			}
			if(wordList.indexOf(word) != -1) {
				System.out.println("No");
				return;
			}
			wordList.add(word);
			beforeWord = word;
		} {
			String word = sc.next();
			if(!beforeWord.substring(beforeWord.length()-1).equals(
					word.substring(0, 1))) {
				System.out.println("No");
				return;
			}
			if(wordList.indexOf(word) != -1) {
				System.out.println("No");
				return;
			}
			wordList.add(word);
			beforeWord = word;
		} String word = sc.next(); word sc.next() sc.next sc if(!beforeWord.substring(beforeWord.length()-1).equals(
					word.substring(0, 1))) {
				System.out.println("No");
				return;
			} !beforeWord.substring(beforeWord.length()-1).equals(
					word.substring(0, 1)) beforeWord.substring(beforeWord.length()-1).equals(
					word.substring(0, 1)) beforeWord.substring(beforeWord.length()-1).equals beforeWord.substring(beforeWord.length()-1) beforeWord.substring beforeWord beforeWord.length()-1 beforeWord.length() beforeWord.length beforeWord 1 word.substring(0, 1) word.substring word 0 1 {
				System.out.println("No");
				return;
			} System.out.println("No") System.out.println System.out System System.out "No" return; if(wordList.indexOf(word) != -1) {
				System.out.println("No");
				return;
			} wordList.indexOf(word) != -1 wordList.indexOf(word) wordList.indexOf wordList word -1 1 {
				System.out.println("No");
				return;
			} System.out.println("No") System.out.println System.out System System.out "No" return; wordList.add(word) wordList.add wordList word beforeWord = word beforeWord word 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();
		List<String> wordList = new ArrayList<String>();
		String beforeWord = sc.next();
		wordList.add(beforeWord);
		for(int i =1;i <n;i++) {
			String word = sc.next();
			if(!beforeWord.substring(beforeWord.length()-1).equals(
					word.substring(0, 1))) {
				System.out.println("No");
				return;
			}
			if(wordList.indexOf(word) != -1) {
				System.out.println("No");
				return;
			}
			wordList.add(word);
			beforeWord = word;
		}
		System.out.println("Yes");
	}
} public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		List<String> wordList = new ArrayList<String>();
		String beforeWord = sc.next();
		wordList.add(beforeWord);
		for(int i =1;i <n;i++) {
			String word = sc.next();
			if(!beforeWord.substring(beforeWord.length()-1).equals(
					word.substring(0, 1))) {
				System.out.println("No");
				return;
			}
			if(wordList.indexOf(word) != -1) {
				System.out.println("No");
				return;
			}
			wordList.add(word);
			beforeWord = word;
		}
		System.out.println("Yes");
	}
} Main
import java.util.ArrayList;
import java.util.List;
import java.util.Scanner;

public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		List<String> wordList = new ArrayList<String>();
		String beforeWord = sc.next();
		wordList.add(beforeWord);
		for(int i =1;i <n;i++) {
			String word = sc.next();
			if(!beforeWord.substring(beforeWord.length()-1).equals(
					word.substring(0, 1))) {
				System.out.println("No");
				return;
			}
			if(wordList.indexOf(word) != -1) {
				System.out.println("No");
				return;
			}
			wordList.add(word);
			beforeWord = word;
		}
		System.out.println("Yes");
	}
}