import java.io.InputStream;
import java.io.PrintStream;
import java.util.HashSet;
import java.util.Scanner;
import java.util.Set;

public class Main {
	InputStream in = System.in;
	PrintStream out = System.out;

	public void _main(String[] args) {
		Scanner sc = new Scanner(in);

		int N = sc.nextInt();

		Set<String> used = new HashSet<>();
		String prevW;

		String ans = "Yes";
		prevW = sc.next();
		used.add(prevW);
		for (int i = 1; i < N; i++) {
			String w = sc.next();
			if (used.contains(w) || w.charAt(0) != prevW.charAt(prevW.length() - 1)) {
				ans = "No";
				break;
			}

			prevW = w;
			used.add(w);
		}

		out.println(ans);

		sc.close();

	}

	public static void main(String[] args) {
		new Main()._main(args);
	}

} import java.io.InputStream; InputStream java.io import java.io.PrintStream; PrintStream java.io import java.util.HashSet; HashSet java.util import java.util.Scanner; Scanner java.util import java.util.Set; Set java.util public class Main {
	InputStream in = System.in;
	PrintStream out = System.out;

	public void _main(String[] args) {
		Scanner sc = new Scanner(in);

		int N = sc.nextInt();

		Set<String> used = new HashSet<>();
		String prevW;

		String ans = "Yes";
		prevW = sc.next();
		used.add(prevW);
		for (int i = 1; i < N; i++) {
			String w = sc.next();
			if (used.contains(w) || w.charAt(0) != prevW.charAt(prevW.length() - 1)) {
				ans = "No";
				break;
			}

			prevW = w;
			used.add(w);
		}

		out.println(ans);

		sc.close();

	}

	public static void main(String[] args) {
		new Main()._main(args);
	}

} Main InputStream in = System.in; in System.in System System.in PrintStream out = System.out; out System.out System System.out public void _main(String[] args) {
		Scanner sc = new Scanner(in);

		int N = sc.nextInt();

		Set<String> used = new HashSet<>();
		String prevW;

		String ans = "Yes";
		prevW = sc.next();
		used.add(prevW);
		for (int i = 1; i < N; i++) {
			String w = sc.next();
			if (used.contains(w) || w.charAt(0) != prevW.charAt(prevW.length() - 1)) {
				ans = "No";
				break;
			}

			prevW = w;
			used.add(w);
		}

		out.println(ans);

		sc.close();

	} _main {
		Scanner sc = new Scanner(in);

		int N = sc.nextInt();

		Set<String> used = new HashSet<>();
		String prevW;

		String ans = "Yes";
		prevW = sc.next();
		used.add(prevW);
		for (int i = 1; i < N; i++) {
			String w = sc.next();
			if (used.contains(w) || w.charAt(0) != prevW.charAt(prevW.length() - 1)) {
				ans = "No";
				break;
			}

			prevW = w;
			used.add(w);
		}

		out.println(ans);

		sc.close();

	} Scanner sc = new Scanner(in); sc new Scanner(in) int N = sc.nextInt(); N sc.nextInt() sc.nextInt sc Set<String> used = new HashSet<>(); used new HashSet<>() String prevW; prevW String ans = "Yes"; ans "Yes" prevW = sc.next() prevW sc.next() sc.next sc used.add(prevW) used.add used prevW for (int i = 1; i < N; i++) {
			String w = sc.next();
			if (used.contains(w) || w.charAt(0) != prevW.charAt(prevW.length() - 1)) {
				ans = "No";
				break;
			}

			prevW = w;
			used.add(w);
		} int i = 1; int i = 1; i 1 i < N i N i++ i++ i {
			String w = sc.next();
			if (used.contains(w) || w.charAt(0) != prevW.charAt(prevW.length() - 1)) {
				ans = "No";
				break;
			}

			prevW = w;
			used.add(w);
		} {
			String w = sc.next();
			if (used.contains(w) || w.charAt(0) != prevW.charAt(prevW.length() - 1)) {
				ans = "No";
				break;
			}

			prevW = w;
			used.add(w);
		} String w = sc.next(); w sc.next() sc.next sc if (used.contains(w) || w.charAt(0) != prevW.charAt(prevW.length() - 1)) {
				ans = "No";
				break;
			} used.contains(w) || w.charAt(0) != prevW.charAt(prevW.length() - 1) used.contains(w) used.contains used w w.charAt(0) != prevW.charAt(prevW.length() - 1) w.charAt(0) w.charAt w 0 prevW.charAt(prevW.length() - 1) prevW.charAt prevW prevW.length() - 1 prevW.length() prevW.length prevW 1 {
				ans = "No";
				break;
			} ans = "No" ans "No" break; prevW = w prevW w used.add(w) used.add used w out.println(ans) out.println out ans sc.close() sc.close sc String[] args args public static void main(String[] args) {
		new Main()._main(args);
	} main {
		new Main()._main(args);
	} new Main()._main(args) new Main()._main new Main() args String[] args args public class Main {
	InputStream in = System.in;
	PrintStream out = System.out;

	public void _main(String[] args) {
		Scanner sc = new Scanner(in);

		int N = sc.nextInt();

		Set<String> used = new HashSet<>();
		String prevW;

		String ans = "Yes";
		prevW = sc.next();
		used.add(prevW);
		for (int i = 1; i < N; i++) {
			String w = sc.next();
			if (used.contains(w) || w.charAt(0) != prevW.charAt(prevW.length() - 1)) {
				ans = "No";
				break;
			}

			prevW = w;
			used.add(w);
		}

		out.println(ans);

		sc.close();

	}

	public static void main(String[] args) {
		new Main()._main(args);
	}

} public class Main {
	InputStream in = System.in;
	PrintStream out = System.out;

	public void _main(String[] args) {
		Scanner sc = new Scanner(in);

		int N = sc.nextInt();

		Set<String> used = new HashSet<>();
		String prevW;

		String ans = "Yes";
		prevW = sc.next();
		used.add(prevW);
		for (int i = 1; i < N; i++) {
			String w = sc.next();
			if (used.contains(w) || w.charAt(0) != prevW.charAt(prevW.length() - 1)) {
				ans = "No";
				break;
			}

			prevW = w;
			used.add(w);
		}

		out.println(ans);

		sc.close();

	}

	public static void main(String[] args) {
		new Main()._main(args);
	}

} Main
import java.io.InputStream;
import java.io.PrintStream;
import java.util.HashSet;
import java.util.Scanner;
import java.util.Set;

public class Main {
	InputStream in = System.in;
	PrintStream out = System.out;

	public void _main(String[] args) {
		Scanner sc = new Scanner(in);

		int N = sc.nextInt();

		Set<String> used = new HashSet<>();
		String prevW;

		String ans = "Yes";
		prevW = sc.next();
		used.add(prevW);
		for (int i = 1; i < N; i++) {
			String w = sc.next();
			if (used.contains(w) || w.charAt(0) != prevW.charAt(prevW.length() - 1)) {
				ans = "No";
				break;
			}

			prevW = w;
			used.add(w);
		}

		out.println(ans);

		sc.close();

	}

	public static void main(String[] args) {
		new Main()._main(args);
	}

}
