#include <bits/stdc++.h>
using namespace std;
int main() {
  string a, b, c;
  int n;
  cin >> n;
  b = "<3";
  while (n--) {
    cin >> a;
    c += b + a;
  }
  c += b;
  cin >> a;
  int len = a.length();
  int j = 0;
  for (int i = 0; i < len; i++) {
    if (a[i] == c[j]) j++;
  }
  if (j == c.length())
    cout << "yes" << endl;
  else
    cout << "no" << endl;
}
