import java.util.Scanner;
import java.util.Arrays;


public class Main {
  public static void main (String[] args) {
    Scanner reader = new Scanner(System.in);
    int A = reader.nextInt();
    String[] list = new String[A];
    for (int i = 0; i < A; i++) {
    	list[i] = reader.next();
      	if (i > 0) {
          if (list[i-1].charAt(list[i-1].length() - 1) !=  list[i].charAt(0)) {
            System.out.print("No");
              return;
          }
          for (int j = i - 1; j >= 0; j--) {
          	if (list[j].equals(list[i])) {
             System.out.print("No");
              return;
            }
          }
        }
    }
    
    System.out.print("Yes");
    
}
  
} import java.util.Scanner; Scanner java.util import java.util.Arrays; Arrays java.util public class Main {
  public static void main (String[] args) {
    Scanner reader = new Scanner(System.in);
    int A = reader.nextInt();
    String[] list = new String[A];
    for (int i = 0; i < A; i++) {
    	list[i] = reader.next();
      	if (i > 0) {
          if (list[i-1].charAt(list[i-1].length() - 1) !=  list[i].charAt(0)) {
            System.out.print("No");
              return;
          }
          for (int j = i - 1; j >= 0; j--) {
          	if (list[j].equals(list[i])) {
             System.out.print("No");
              return;
            }
          }
        }
    }
    
    System.out.print("Yes");
    
}
  
} Main public static void main (String[] args) {
    Scanner reader = new Scanner(System.in);
    int A = reader.nextInt();
    String[] list = new String[A];
    for (int i = 0; i < A; i++) {
    	list[i] = reader.next();
      	if (i > 0) {
          if (list[i-1].charAt(list[i-1].length() - 1) !=  list[i].charAt(0)) {
            System.out.print("No");
              return;
          }
          for (int j = i - 1; j >= 0; j--) {
          	if (list[j].equals(list[i])) {
             System.out.print("No");
              return;
            }
          }
        }
    }
    
    System.out.print("Yes");
    
} main {
    Scanner reader = new Scanner(System.in);
    int A = reader.nextInt();
    String[] list = new String[A];
    for (int i = 0; i < A; i++) {
    	list[i] = reader.next();
      	if (i > 0) {
          if (list[i-1].charAt(list[i-1].length() - 1) !=  list[i].charAt(0)) {
            System.out.print("No");
              return;
          }
          for (int j = i - 1; j >= 0; j--) {
          	if (list[j].equals(list[i])) {
             System.out.print("No");
              return;
            }
          }
        }
    }
    
    System.out.print("Yes");
    
} Scanner reader = new Scanner(System.in); reader new Scanner(System.in) int A = reader.nextInt(); A reader.nextInt() reader.nextInt reader String[] list = new String[A]; list new String[A] A for (int i = 0; i < A; i++) {
    	list[i] = reader.next();
      	if (i > 0) {
          if (list[i-1].charAt(list[i-1].length() - 1) !=  list[i].charAt(0)) {
            System.out.print("No");
              return;
          }
          for (int j = i - 1; j >= 0; j--) {
          	if (list[j].equals(list[i])) {
             System.out.print("No");
              return;
            }
          }
        }
    } int i = 0; int i = 0; i 0 i < A i A i++ i++ i {
    	list[i] = reader.next();
      	if (i > 0) {
          if (list[i-1].charAt(list[i-1].length() - 1) !=  list[i].charAt(0)) {
            System.out.print("No");
              return;
          }
          for (int j = i - 1; j >= 0; j--) {
          	if (list[j].equals(list[i])) {
             System.out.print("No");
              return;
            }
          }
        }
    } {
    	list[i] = reader.next();
      	if (i > 0) {
          if (list[i-1].charAt(list[i-1].length() - 1) !=  list[i].charAt(0)) {
            System.out.print("No");
              return;
          }
          for (int j = i - 1; j >= 0; j--) {
          	if (list[j].equals(list[i])) {
             System.out.print("No");
              return;
            }
          }
        }
    } list[i] = reader.next() list[i] list i reader.next() reader.next reader if (i > 0) {
          if (list[i-1].charAt(list[i-1].length() - 1) !=  list[i].charAt(0)) {
            System.out.print("No");
              return;
          }
          for (int j = i - 1; j >= 0; j--) {
          	if (list[j].equals(list[i])) {
             System.out.print("No");
              return;
            }
          }
        } i > 0 i 0 {
          if (list[i-1].charAt(list[i-1].length() - 1) !=  list[i].charAt(0)) {
            System.out.print("No");
              return;
          }
          for (int j = i - 1; j >= 0; j--) {
          	if (list[j].equals(list[i])) {
             System.out.print("No");
              return;
            }
          }
        } if (list[i-1].charAt(list[i-1].length() - 1) !=  list[i].charAt(0)) {
            System.out.print("No");
              return;
          } list[i-1].charAt(list[i-1].length() - 1) !=  list[i].charAt(0) list[i-1].charAt(list[i-1].length() - 1) list[i-1].charAt list[i-1] list i-1 i 1 list[i-1].length() - 1 list[i-1].length() list[i-1].length list[i-1] list i-1 i 1 1 list[i].charAt(0) list[i].charAt list[i] list i 0 {
            System.out.print("No");
              return;
          } System.out.print("No") System.out.print System.out System System.out "No" return; for (int j = i - 1; j >= 0; j--) {
          	if (list[j].equals(list[i])) {
             System.out.print("No");
              return;
            }
          } int j = i - 1; int j = i - 1; j i - 1 i 1 j >= 0 j 0 j-- j-- j {
          	if (list[j].equals(list[i])) {
             System.out.print("No");
              return;
            }
          } {
          	if (list[j].equals(list[i])) {
             System.out.print("No");
              return;
            }
          } if (list[j].equals(list[i])) {
             System.out.print("No");
              return;
            } list[j].equals(list[i]) list[j].equals list[j] list j list[i] list i {
             System.out.print("No");
              return;
            } System.out.print("No") System.out.print System.out System System.out "No" return; System.out.print("Yes") System.out.print System.out System System.out "Yes" String[] args args public class Main {
  public static void main (String[] args) {
    Scanner reader = new Scanner(System.in);
    int A = reader.nextInt();
    String[] list = new String[A];
    for (int i = 0; i < A; i++) {
    	list[i] = reader.next();
      	if (i > 0) {
          if (list[i-1].charAt(list[i-1].length() - 1) !=  list[i].charAt(0)) {
            System.out.print("No");
              return;
          }
          for (int j = i - 1; j >= 0; j--) {
          	if (list[j].equals(list[i])) {
             System.out.print("No");
              return;
            }
          }
        }
    }
    
    System.out.print("Yes");
    
}
  
} public class Main {
  public static void main (String[] args) {
    Scanner reader = new Scanner(System.in);
    int A = reader.nextInt();
    String[] list = new String[A];
    for (int i = 0; i < A; i++) {
    	list[i] = reader.next();
      	if (i > 0) {
          if (list[i-1].charAt(list[i-1].length() - 1) !=  list[i].charAt(0)) {
            System.out.print("No");
              return;
          }
          for (int j = i - 1; j >= 0; j--) {
          	if (list[j].equals(list[i])) {
             System.out.print("No");
              return;
            }
          }
        }
    }
    
    System.out.print("Yes");
    
}
  
} Main
import java.util.Scanner;
import java.util.Arrays;


public class Main {
  public static void main (String[] args) {
    Scanner reader = new Scanner(System.in);
    int A = reader.nextInt();
    String[] list = new String[A];
    for (int i = 0; i < A; i++) {
    	list[i] = reader.next();
      	if (i > 0) {
          if (list[i-1].charAt(list[i-1].length() - 1) !=  list[i].charAt(0)) {
            System.out.print("No");
              return;
          }
          for (int j = i - 1; j >= 0; j--) {
          	if (list[j].equals(list[i])) {
             System.out.print("No");
              return;
            }
          }
        }
    }
    
    System.out.print("Yes");
    
}
  
}