#include <bits/stdc++.h>
using namespace std;
int n;
string s, t;
bool u[1001];
int main() {
  getline(cin, s);
  getline(cin, t);
  bool bo;
  for (int i = 0; i <= t.length() - 1; i++) {
    bo = 0;
    if (t[i] == ' ') continue;
    for (int j = 0; j <= s.length() - 1; j++) {
      if (s[j] == t[i] && !u[j]) {
        u[j] = 1;
        bo = 1;
        break;
      }
    }
    if (!bo) {
      cout << "NO";
      return 0;
    }
  }
  cout << "YES";
  fclose(stdin);
  fclose(stdout);
  return 0;
}
