#include <bits/stdc++.h>
using namespace std;
int main() {
  map<char, int> m;
  string s1, s2;
  getline(cin, s1);
  cin >> ws;
  getline(cin, s2);
  for (int i = 0; i < s1.size(); i++) {
    if (m.count(s1[i]))
      m[s1[i]]++;
    else
      m[s1[i]] = 1;
  }
  for (int i = 0; i < s2.size(); i++) {
    if (s2[i] == ' ') continue;
    if (!m.count(s2[i]) || m[s2[i]] <= 0) {
      cout << "NO" << endl;
      return 0;
    } else
      m[s2[i]]--;
  }
  cout << "YES" << endl;
  return 0;
}
