import java.util.*;
import java.lang.Math;

public class Main {
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    
   	int n = sc.nextInt();
    String stack;
    char cstack;
    List words = new ArrayList();
    boolean con = true;
    
    stack = sc.next();
    cstack = stack.charAt(stack.length()-1);
   	words.add(stack);
    
    for(int i = 1;i < n && con;i++){
      	stack = sc.next();
    	if(words.contains(stack) || stack.charAt(0) != cstack) con = false;
      	else{
        	cstack = stack.charAt(stack.length()-1);
   			words.add(stack);
        }
    }
    
    if(con) System.out.println("Yes");
    else System.out.println("No");

  }
} import java.util.*; util.* java import java.lang.Math; Math java.lang public class Main {
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    
   	int n = sc.nextInt();
    String stack;
    char cstack;
    List words = new ArrayList();
    boolean con = true;
    
    stack = sc.next();
    cstack = stack.charAt(stack.length()-1);
   	words.add(stack);
    
    for(int i = 1;i < n && con;i++){
      	stack = sc.next();
    	if(words.contains(stack) || stack.charAt(0) != cstack) con = false;
      	else{
        	cstack = stack.charAt(stack.length()-1);
   			words.add(stack);
        }
    }
    
    if(con) System.out.println("Yes");
    else System.out.println("No");

  }
} Main public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    
   	int n = sc.nextInt();
    String stack;
    char cstack;
    List words = new ArrayList();
    boolean con = true;
    
    stack = sc.next();
    cstack = stack.charAt(stack.length()-1);
   	words.add(stack);
    
    for(int i = 1;i < n && con;i++){
      	stack = sc.next();
    	if(words.contains(stack) || stack.charAt(0) != cstack) con = false;
      	else{
        	cstack = stack.charAt(stack.length()-1);
   			words.add(stack);
        }
    }
    
    if(con) System.out.println("Yes");
    else System.out.println("No");

  } main {
    Scanner sc = new Scanner(System.in);
    
   	int n = sc.nextInt();
    String stack;
    char cstack;
    List words = new ArrayList();
    boolean con = true;
    
    stack = sc.next();
    cstack = stack.charAt(stack.length()-1);
   	words.add(stack);
    
    for(int i = 1;i < n && con;i++){
      	stack = sc.next();
    	if(words.contains(stack) || stack.charAt(0) != cstack) con = false;
      	else{
        	cstack = stack.charAt(stack.length()-1);
   			words.add(stack);
        }
    }
    
    if(con) System.out.println("Yes");
    else System.out.println("No");

  } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc String stack; stack char cstack; cstack List words = new ArrayList(); words new ArrayList() boolean con = true; con true stack = sc.next() stack sc.next() sc.next sc cstack = stack.charAt(stack.length()-1) cstack stack.charAt(stack.length()-1) stack.charAt stack stack.length()-1 stack.length() stack.length stack 1 words.add(stack) words.add words stack for(int i = 1;i < n && con;i++){
      	stack = sc.next();
    	if(words.contains(stack) || stack.charAt(0) != cstack) con = false;
      	else{
        	cstack = stack.charAt(stack.length()-1);
   			words.add(stack);
        }
    } int i = 1; int i = 1; i 1 i < n && con i < n i n con i++ i++ i {
      	stack = sc.next();
    	if(words.contains(stack) || stack.charAt(0) != cstack) con = false;
      	else{
        	cstack = stack.charAt(stack.length()-1);
   			words.add(stack);
        }
    } {
      	stack = sc.next();
    	if(words.contains(stack) || stack.charAt(0) != cstack) con = false;
      	else{
        	cstack = stack.charAt(stack.length()-1);
   			words.add(stack);
        }
    } stack = sc.next() stack sc.next() sc.next sc if(words.contains(stack) || stack.charAt(0) != cstack) con = false;
      	else{
        	cstack = stack.charAt(stack.length()-1);
   			words.add(stack);
        } words.contains(stack) || stack.charAt(0) != cstack words.contains(stack) words.contains words stack stack.charAt(0) != cstack stack.charAt(0) stack.charAt stack 0 cstack con = false con false {
        	cstack = stack.charAt(stack.length()-1);
   			words.add(stack);
        } cstack = stack.charAt(stack.length()-1) cstack stack.charAt(stack.length()-1) stack.charAt stack stack.length()-1 stack.length() stack.length stack 1 words.add(stack) words.add words stack if(con) System.out.println("Yes");
    else System.out.println("No"); con System.out.println("Yes") System.out.println System.out System System.out "Yes" 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);
    
   	int n = sc.nextInt();
    String stack;
    char cstack;
    List words = new ArrayList();
    boolean con = true;
    
    stack = sc.next();
    cstack = stack.charAt(stack.length()-1);
   	words.add(stack);
    
    for(int i = 1;i < n && con;i++){
      	stack = sc.next();
    	if(words.contains(stack) || stack.charAt(0) != cstack) con = false;
      	else{
        	cstack = stack.charAt(stack.length()-1);
   			words.add(stack);
        }
    }
    
    if(con) System.out.println("Yes");
    else System.out.println("No");

  }
} public class Main {
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    
   	int n = sc.nextInt();
    String stack;
    char cstack;
    List words = new ArrayList();
    boolean con = true;
    
    stack = sc.next();
    cstack = stack.charAt(stack.length()-1);
   	words.add(stack);
    
    for(int i = 1;i < n && con;i++){
      	stack = sc.next();
    	if(words.contains(stack) || stack.charAt(0) != cstack) con = false;
      	else{
        	cstack = stack.charAt(stack.length()-1);
   			words.add(stack);
        }
    }
    
    if(con) System.out.println("Yes");
    else System.out.println("No");

  }
} Main
import java.util.*;
import java.lang.Math;

public class Main {
  public static void main(String[] args) {
    Scanner sc = new Scanner(System.in);
    
   	int n = sc.nextInt();
    String stack;
    char cstack;
    List words = new ArrayList();
    boolean con = true;
    
    stack = sc.next();
    cstack = stack.charAt(stack.length()-1);
   	words.add(stack);
    
    for(int i = 1;i < n && con;i++){
      	stack = sc.next();
    	if(words.contains(stack) || stack.charAt(0) != cstack) con = false;
      	else{
        	cstack = stack.charAt(stack.length()-1);
   			words.add(stack);
        }
    }
    
    if(con) System.out.println("Yes");
    else System.out.println("No");

  }
}
