#include <bits/stdc++.h>
using namespace std;
string res, s[100005], temp, given;
int main() {
  std::ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  int n, pos;
  bool valid = false;
  temp = "<3";
  cin >> n;
  res = "";
  res += temp;
  for (int i = 0; i < n; i++) {
    cin >> s[i];
    res += s[i];
    res += temp;
  }
  pos = 0;
  cin >> given;
  for (int i = 0; i < given.length(); i++) {
    if (given[i] == res[pos]) pos++;
    if (pos == res.length()) {
      valid = true;
      break;
    }
  }
  if (valid)
    cout << "yes\n";
  else
    cout << "no\n";
  return 0;
}
