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> s = new ArrayList<>();
		for(int i=0; i<N; i++) {
			String word = sc.next();
			if(s.contains(word)) {
				System.out.println("No");
				return;
			}
			s.add(word);
		}

		char c = s.get(0).charAt(0);
		for (String w : s) {
			if(w.charAt(0) == c) {
				c = w.charAt(w.length()-1);
			}else {
				System.out.println("No");
				return;
			}
		}
		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> s = new ArrayList<>();
		for(int i=0; i<N; i++) {
			String word = sc.next();
			if(s.contains(word)) {
				System.out.println("No");
				return;
			}
			s.add(word);
		}

		char c = s.get(0).charAt(0);
		for (String w : s) {
			if(w.charAt(0) == c) {
				c = w.charAt(w.length()-1);
			}else {
				System.out.println("No");
				return;
			}
		}
		System.out.println("Yes");
	}

} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int N=sc.nextInt();
		List<String> s = new ArrayList<>();
		for(int i=0; i<N; i++) {
			String word = sc.next();
			if(s.contains(word)) {
				System.out.println("No");
				return;
			}
			s.add(word);
		}

		char c = s.get(0).charAt(0);
		for (String w : s) {
			if(w.charAt(0) == c) {
				c = w.charAt(w.length()-1);
			}else {
				System.out.println("No");
				return;
			}
		}
		System.out.println("Yes");
	} main {
		Scanner sc = new Scanner(System.in);
		int N=sc.nextInt();
		List<String> s = new ArrayList<>();
		for(int i=0; i<N; i++) {
			String word = sc.next();
			if(s.contains(word)) {
				System.out.println("No");
				return;
			}
			s.add(word);
		}

		char c = s.get(0).charAt(0);
		for (String w : s) {
			if(w.charAt(0) == c) {
				c = w.charAt(w.length()-1);
			}else {
				System.out.println("No");
				return;
			}
		}
		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> s = new ArrayList<>(); s new ArrayList<>() for(int i=0; i<N; i++) {
			String word = sc.next();
			if(s.contains(word)) {
				System.out.println("No");
				return;
			}
			s.add(word);
		} int i=0; int i=0; i 0 i<N i N i++ i++ i {
			String word = sc.next();
			if(s.contains(word)) {
				System.out.println("No");
				return;
			}
			s.add(word);
		} {
			String word = sc.next();
			if(s.contains(word)) {
				System.out.println("No");
				return;
			}
			s.add(word);
		} String word = sc.next(); word sc.next() sc.next sc if(s.contains(word)) {
				System.out.println("No");
				return;
			} s.contains(word) s.contains s word {
				System.out.println("No");
				return;
			} System.out.println("No") System.out.println System.out System System.out "No" return; s.add(word) s.add s word char c = s.get(0).charAt(0); c s.get(0).charAt(0) s.get(0).charAt s.get(0) s.get s 0 0 for (String w : s) {
			if(w.charAt(0) == c) {
				c = w.charAt(w.length()-1);
			}else {
				System.out.println("No");
				return;
			}
		} String w s {
			if(w.charAt(0) == c) {
				c = w.charAt(w.length()-1);
			}else {
				System.out.println("No");
				return;
			}
		} {
			if(w.charAt(0) == c) {
				c = w.charAt(w.length()-1);
			}else {
				System.out.println("No");
				return;
			}
		} if(w.charAt(0) == c) {
				c = w.charAt(w.length()-1);
			}else {
				System.out.println("No");
				return;
			} w.charAt(0) == c w.charAt(0) w.charAt w 0 c {
				c = w.charAt(w.length()-1);
			} c = w.charAt(w.length()-1) c w.charAt(w.length()-1) w.charAt w w.length()-1 w.length() w.length w 1 {
				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 sc = new Scanner(System.in);
		int N=sc.nextInt();
		List<String> s = new ArrayList<>();
		for(int i=0; i<N; i++) {
			String word = sc.next();
			if(s.contains(word)) {
				System.out.println("No");
				return;
			}
			s.add(word);
		}

		char c = s.get(0).charAt(0);
		for (String w : s) {
			if(w.charAt(0) == c) {
				c = w.charAt(w.length()-1);
			}else {
				System.out.println("No");
				return;
			}
		}
		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> s = new ArrayList<>();
		for(int i=0; i<N; i++) {
			String word = sc.next();
			if(s.contains(word)) {
				System.out.println("No");
				return;
			}
			s.add(word);
		}

		char c = s.get(0).charAt(0);
		for (String w : s) {
			if(w.charAt(0) == c) {
				c = w.charAt(w.length()-1);
			}else {
				System.out.println("No");
				return;
			}
		}
		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> s = new ArrayList<>();
		for(int i=0; i<N; i++) {
			String word = sc.next();
			if(s.contains(word)) {
				System.out.println("No");
				return;
			}
			s.add(word);
		}

		char c = s.get(0).charAt(0);
		for (String w : s) {
			if(w.charAt(0) == c) {
				c = w.charAt(w.length()-1);
			}else {
				System.out.println("No");
				return;
			}
		}
		System.out.println("Yes");
	}

}
