import java.util.HashMap;
import java.util.Map;
import java.util.Scanner;

class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		String[] w = new String[n];
		for (int i = 0; i < n; i++) {
			w[i] = sc.next();
		}
		char last = w[0].charAt(0);
		Map<String, Integer> map = new HashMap<>();
		for (int i = 0; i < n; i++) {
			if (map.containsKey(w[i])) {
				System.out.println("No");
				return;
			} else {
				map.put(w[i], 1);
			}
			if (w[i].charAt(0) != last) {
				System.out.println("No");
				return;
			} else {
				last = w[i].charAt(w[i].length()-1);
			}
		}
		System.out.println("Yes");
	}
} import java.util.HashMap; HashMap java.util import java.util.Map; Map java.util import java.util.Scanner; Scanner java.util class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		String[] w = new String[n];
		for (int i = 0; i < n; i++) {
			w[i] = sc.next();
		}
		char last = w[0].charAt(0);
		Map<String, Integer> map = new HashMap<>();
		for (int i = 0; i < n; i++) {
			if (map.containsKey(w[i])) {
				System.out.println("No");
				return;
			} else {
				map.put(w[i], 1);
			}
			if (w[i].charAt(0) != last) {
				System.out.println("No");
				return;
			} else {
				last = w[i].charAt(w[i].length()-1);
			}
		}
		System.out.println("Yes");
	}
} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		String[] w = new String[n];
		for (int i = 0; i < n; i++) {
			w[i] = sc.next();
		}
		char last = w[0].charAt(0);
		Map<String, Integer> map = new HashMap<>();
		for (int i = 0; i < n; i++) {
			if (map.containsKey(w[i])) {
				System.out.println("No");
				return;
			} else {
				map.put(w[i], 1);
			}
			if (w[i].charAt(0) != last) {
				System.out.println("No");
				return;
			} else {
				last = w[i].charAt(w[i].length()-1);
			}
		}
		System.out.println("Yes");
	} main {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		String[] w = new String[n];
		for (int i = 0; i < n; i++) {
			w[i] = sc.next();
		}
		char last = w[0].charAt(0);
		Map<String, Integer> map = new HashMap<>();
		for (int i = 0; i < n; i++) {
			if (map.containsKey(w[i])) {
				System.out.println("No");
				return;
			} else {
				map.put(w[i], 1);
			}
			if (w[i].charAt(0) != last) {
				System.out.println("No");
				return;
			} else {
				last = w[i].charAt(w[i].length()-1);
			}
		}
		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 String[] w = new String[n]; w new String[n] n for (int i = 0; i < n; i++) {
			w[i] = sc.next();
		} int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
			w[i] = sc.next();
		} {
			w[i] = sc.next();
		} w[i] = sc.next() w[i] w i sc.next() sc.next sc char last = w[0].charAt(0); last w[0].charAt(0) w[0].charAt w[0] w 0 0 Map<String, Integer> map = new HashMap<>(); map new HashMap<>() for (int i = 0; i < n; i++) {
			if (map.containsKey(w[i])) {
				System.out.println("No");
				return;
			} else {
				map.put(w[i], 1);
			}
			if (w[i].charAt(0) != last) {
				System.out.println("No");
				return;
			} else {
				last = w[i].charAt(w[i].length()-1);
			}
		} int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
			if (map.containsKey(w[i])) {
				System.out.println("No");
				return;
			} else {
				map.put(w[i], 1);
			}
			if (w[i].charAt(0) != last) {
				System.out.println("No");
				return;
			} else {
				last = w[i].charAt(w[i].length()-1);
			}
		} {
			if (map.containsKey(w[i])) {
				System.out.println("No");
				return;
			} else {
				map.put(w[i], 1);
			}
			if (w[i].charAt(0) != last) {
				System.out.println("No");
				return;
			} else {
				last = w[i].charAt(w[i].length()-1);
			}
		} if (map.containsKey(w[i])) {
				System.out.println("No");
				return;
			} else {
				map.put(w[i], 1);
			} map.containsKey(w[i]) map.containsKey map w[i] w i {
				System.out.println("No");
				return;
			} System.out.println("No") System.out.println System.out System System.out "No" return; {
				map.put(w[i], 1);
			} map.put(w[i], 1) map.put map w[i] w i 1 if (w[i].charAt(0) != last) {
				System.out.println("No");
				return;
			} else {
				last = w[i].charAt(w[i].length()-1);
			} w[i].charAt(0) != last w[i].charAt(0) w[i].charAt w[i] w i 0 last {
				System.out.println("No");
				return;
			} System.out.println("No") System.out.println System.out System System.out "No" return; {
				last = w[i].charAt(w[i].length()-1);
			} last = w[i].charAt(w[i].length()-1) last w[i].charAt(w[i].length()-1) w[i].charAt w[i] w i w[i].length()-1 w[i].length() w[i].length w[i] w i 1 System.out.println("Yes") System.out.println System.out System System.out "Yes" String[] args args
import java.util.HashMap;
import java.util.Map;
import java.util.Scanner;

class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		String[] w = new String[n];
		for (int i = 0; i < n; i++) {
			w[i] = sc.next();
		}
		char last = w[0].charAt(0);
		Map<String, Integer> map = new HashMap<>();
		for (int i = 0; i < n; i++) {
			if (map.containsKey(w[i])) {
				System.out.println("No");
				return;
			} else {
				map.put(w[i], 1);
			}
			if (w[i].charAt(0) != last) {
				System.out.println("No");
				return;
			} else {
				last = w[i].charAt(w[i].length()-1);
			}
		}
		System.out.println("Yes");
	}
}
