#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, l = 0;
  cin >> n;
  string s1, s2, s;
  s += "<3";
  for (int i = 0; i < n; i++) {
    cin >> s1;
    s += s1;
    s += "<3";
  }
  cin >> s2;
  int k = s.size();
  int d = s2.size();
  l = 0;
  for (int i = 0; i < d; i++) {
    if (s2[i] == s[l]) l++;
  }
  if (l == k)
    cout << "yes" << endl;
  else
    cout << "no" << endl;
  return 0;
}
