#include <bits/stdc++.h>
using namespace std;
const int inf = (int)1e9;
const double INF = 1e12, EPS = 1e-9;
int n;
string s, t;
int main() {
  string h = "<3";
  cin >> n;
  for (int i = 0; i < (int)n; i++) {
    string a;
    cin >> a;
    if (i == 0) s += h;
    s += a;
    s += h;
  }
  cin >> t;
  int i = 0, j = 0;
  for (; i < t.size() && j < s.size(); i++) {
    if (t[i] == s[j]) j++;
  }
  cout << (j == s.size() ? "yes" : "no") << endl;
  return 0;
}
