#include <bits/stdc++.h>
using namespace std;
const int N = 135000;
string str;
string word;
string temp;
bool ok(char a) {
  if (a == '<' || a == '>') return true;
  if (a >= '0' || a <= '9') return true;
  return false;
}
int main() {
  word = "<3";
  int n;
  cin >> n;
  for (int i = 1; i <= n; i++) {
    cin >> str;
    word += str;
    word += "<3";
  }
  cin >> str;
  int len = str.length();
  int len2 = word.length();
  int cnt = 0;
  bool flag = 0;
  int i = 0;
  while (1) {
    if (word[i] == str[cnt]) {
      cnt++;
      i++;
    } else {
      cnt++;
    }
    if (i == len2) {
      flag = 1;
      goto A;
    }
    if (cnt == len) goto A;
  }
A:;
  if (flag)
    printf("yes\n");
  else
    printf("no\n");
  return 0;
}
