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

public class Main {
	public static void main(String[] args) {

		Scanner sc = new Scanner(System.in);
		ArrayList<String> slist = new ArrayList<String>();
		String beforeWord = null;
		String word = null;
		boolean flag = true;
		int size = sc.nextInt();
		if(size > 100){
			flag = false;
			System.out.println("No");
			return;
		}
		word = sc.nextLine();

		for (int i = 0; i < size; i++) {
			word = sc.nextLine();
			if (beforeWord != null) {
				char shiri = beforeWord.charAt(beforeWord.length() - 1);
				char atama = word.charAt(0);
				if (shiri == atama) {
					flag = true;
				} else {
					flag = false;
					break;
				}
			}

			if (!slist.contains(word)) {
				if (flag) {
					slist.add(word);
					beforeWord = word;
				}
			}else{
				flag = false;
				break;
			}

		}
		if (flag) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}

	}
} import java.util.ArrayList; ArrayList java.util import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[] args) {

		Scanner sc = new Scanner(System.in);
		ArrayList<String> slist = new ArrayList<String>();
		String beforeWord = null;
		String word = null;
		boolean flag = true;
		int size = sc.nextInt();
		if(size > 100){
			flag = false;
			System.out.println("No");
			return;
		}
		word = sc.nextLine();

		for (int i = 0; i < size; i++) {
			word = sc.nextLine();
			if (beforeWord != null) {
				char shiri = beforeWord.charAt(beforeWord.length() - 1);
				char atama = word.charAt(0);
				if (shiri == atama) {
					flag = true;
				} else {
					flag = false;
					break;
				}
			}

			if (!slist.contains(word)) {
				if (flag) {
					slist.add(word);
					beforeWord = word;
				}
			}else{
				flag = false;
				break;
			}

		}
		if (flag) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}

	}
} Main public static void main(String[] args) {

		Scanner sc = new Scanner(System.in);
		ArrayList<String> slist = new ArrayList<String>();
		String beforeWord = null;
		String word = null;
		boolean flag = true;
		int size = sc.nextInt();
		if(size > 100){
			flag = false;
			System.out.println("No");
			return;
		}
		word = sc.nextLine();

		for (int i = 0; i < size; i++) {
			word = sc.nextLine();
			if (beforeWord != null) {
				char shiri = beforeWord.charAt(beforeWord.length() - 1);
				char atama = word.charAt(0);
				if (shiri == atama) {
					flag = true;
				} else {
					flag = false;
					break;
				}
			}

			if (!slist.contains(word)) {
				if (flag) {
					slist.add(word);
					beforeWord = word;
				}
			}else{
				flag = false;
				break;
			}

		}
		if (flag) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}

	} main {

		Scanner sc = new Scanner(System.in);
		ArrayList<String> slist = new ArrayList<String>();
		String beforeWord = null;
		String word = null;
		boolean flag = true;
		int size = sc.nextInt();
		if(size > 100){
			flag = false;
			System.out.println("No");
			return;
		}
		word = sc.nextLine();

		for (int i = 0; i < size; i++) {
			word = sc.nextLine();
			if (beforeWord != null) {
				char shiri = beforeWord.charAt(beforeWord.length() - 1);
				char atama = word.charAt(0);
				if (shiri == atama) {
					flag = true;
				} else {
					flag = false;
					break;
				}
			}

			if (!slist.contains(word)) {
				if (flag) {
					slist.add(word);
					beforeWord = word;
				}
			}else{
				flag = false;
				break;
			}

		}
		if (flag) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}

	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) ArrayList<String> slist = new ArrayList<String>(); slist new ArrayList<String>() String beforeWord = null; beforeWord null String word = null; word null boolean flag = true; flag true int size = sc.nextInt(); size sc.nextInt() sc.nextInt sc if(size > 100){
			flag = false;
			System.out.println("No");
			return;
		} size > 100 size 100 {
			flag = false;
			System.out.println("No");
			return;
		} flag = false flag false System.out.println("No") System.out.println System.out System System.out "No" return; word = sc.nextLine() word sc.nextLine() sc.nextLine sc for (int i = 0; i < size; i++) {
			word = sc.nextLine();
			if (beforeWord != null) {
				char shiri = beforeWord.charAt(beforeWord.length() - 1);
				char atama = word.charAt(0);
				if (shiri == atama) {
					flag = true;
				} else {
					flag = false;
					break;
				}
			}

			if (!slist.contains(word)) {
				if (flag) {
					slist.add(word);
					beforeWord = word;
				}
			}else{
				flag = false;
				break;
			}

		} int i = 0; int i = 0; i 0 i < size i size i++ i++ i {
			word = sc.nextLine();
			if (beforeWord != null) {
				char shiri = beforeWord.charAt(beforeWord.length() - 1);
				char atama = word.charAt(0);
				if (shiri == atama) {
					flag = true;
				} else {
					flag = false;
					break;
				}
			}

			if (!slist.contains(word)) {
				if (flag) {
					slist.add(word);
					beforeWord = word;
				}
			}else{
				flag = false;
				break;
			}

		} {
			word = sc.nextLine();
			if (beforeWord != null) {
				char shiri = beforeWord.charAt(beforeWord.length() - 1);
				char atama = word.charAt(0);
				if (shiri == atama) {
					flag = true;
				} else {
					flag = false;
					break;
				}
			}

			if (!slist.contains(word)) {
				if (flag) {
					slist.add(word);
					beforeWord = word;
				}
			}else{
				flag = false;
				break;
			}

		} word = sc.nextLine() word sc.nextLine() sc.nextLine sc if (beforeWord != null) {
				char shiri = beforeWord.charAt(beforeWord.length() - 1);
				char atama = word.charAt(0);
				if (shiri == atama) {
					flag = true;
				} else {
					flag = false;
					break;
				}
			} beforeWord != null beforeWord null {
				char shiri = beforeWord.charAt(beforeWord.length() - 1);
				char atama = word.charAt(0);
				if (shiri == atama) {
					flag = true;
				} else {
					flag = false;
					break;
				}
			} char shiri = beforeWord.charAt(beforeWord.length() - 1); shiri beforeWord.charAt(beforeWord.length() - 1) beforeWord.charAt beforeWord beforeWord.length() - 1 beforeWord.length() beforeWord.length beforeWord 1 char atama = word.charAt(0); atama word.charAt(0) word.charAt word 0 if (shiri == atama) {
					flag = true;
				} else {
					flag = false;
					break;
				} shiri == atama shiri atama {
					flag = true;
				} flag = true flag true {
					flag = false;
					break;
				} flag = false flag false break; if (!slist.contains(word)) {
				if (flag) {
					slist.add(word);
					beforeWord = word;
				}
			}else{
				flag = false;
				break;
			} !slist.contains(word) slist.contains(word) slist.contains slist word {
				if (flag) {
					slist.add(word);
					beforeWord = word;
				}
			} if (flag) {
					slist.add(word);
					beforeWord = word;
				} flag {
					slist.add(word);
					beforeWord = word;
				} slist.add(word) slist.add slist word beforeWord = word beforeWord word {
				flag = false;
				break;
			} flag = false flag false break; if (flag) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		} flag {
			System.out.println("Yes");
		} System.out.println("Yes") System.out.println System.out System System.out "Yes" {
			System.out.println("No");
		} 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) {

		Scanner sc = new Scanner(System.in);
		ArrayList<String> slist = new ArrayList<String>();
		String beforeWord = null;
		String word = null;
		boolean flag = true;
		int size = sc.nextInt();
		if(size > 100){
			flag = false;
			System.out.println("No");
			return;
		}
		word = sc.nextLine();

		for (int i = 0; i < size; i++) {
			word = sc.nextLine();
			if (beforeWord != null) {
				char shiri = beforeWord.charAt(beforeWord.length() - 1);
				char atama = word.charAt(0);
				if (shiri == atama) {
					flag = true;
				} else {
					flag = false;
					break;
				}
			}

			if (!slist.contains(word)) {
				if (flag) {
					slist.add(word);
					beforeWord = word;
				}
			}else{
				flag = false;
				break;
			}

		}
		if (flag) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}

	}
} public class Main {
	public static void main(String[] args) {

		Scanner sc = new Scanner(System.in);
		ArrayList<String> slist = new ArrayList<String>();
		String beforeWord = null;
		String word = null;
		boolean flag = true;
		int size = sc.nextInt();
		if(size > 100){
			flag = false;
			System.out.println("No");
			return;
		}
		word = sc.nextLine();

		for (int i = 0; i < size; i++) {
			word = sc.nextLine();
			if (beforeWord != null) {
				char shiri = beforeWord.charAt(beforeWord.length() - 1);
				char atama = word.charAt(0);
				if (shiri == atama) {
					flag = true;
				} else {
					flag = false;
					break;
				}
			}

			if (!slist.contains(word)) {
				if (flag) {
					slist.add(word);
					beforeWord = word;
				}
			}else{
				flag = false;
				break;
			}

		}
		if (flag) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}

	}
} Main
import java.util.ArrayList;
import java.util.Scanner;

public class Main {
	public static void main(String[] args) {

		Scanner sc = new Scanner(System.in);
		ArrayList<String> slist = new ArrayList<String>();
		String beforeWord = null;
		String word = null;
		boolean flag = true;
		int size = sc.nextInt();
		if(size > 100){
			flag = false;
			System.out.println("No");
			return;
		}
		word = sc.nextLine();

		for (int i = 0; i < size; i++) {
			word = sc.nextLine();
			if (beforeWord != null) {
				char shiri = beforeWord.charAt(beforeWord.length() - 1);
				char atama = word.charAt(0);
				if (shiri == atama) {
					flag = true;
				} else {
					flag = false;
					break;
				}
			}

			if (!slist.contains(word)) {
				if (flag) {
					slist.add(word);
					beforeWord = word;
				}
			}else{
				flag = false;
				break;
			}

		}
		if (flag) {
			System.out.println("Yes");
		} else {
			System.out.println("No");
		}

	}
}