#include <bits/stdc++.h>
using namespace std;
char a[1000100], b[1000100], t[1000100];
int main() {
  int i, j, n, La, Lb, num = 0;
  cin >> n;
  getchar();
  a[num++] = '<';
  a[num++] = '3';
  for (i = 0; i < n; i++) {
    gets(t);
    for (j = 0; t[j] != '\0'; j++) a[num++] = t[j];
    a[num++] = '<';
    a[num++] = '3';
  }
  a[num] = '\0';
  La = strlen(a);
  gets(b);
  Lb = strlen(b);
  i = j = 0;
  while (i < La && j < Lb) {
    if (a[i] == b[j])
      i++, j++;
    else
      j++;
  }
  if (i >= La)
    printf("yes\n");
  else
    printf("no\n");
  return 0;
}
