#include <bits/stdc++.h>
using namespace std;
string yes = "YES\n", no = "NO\n", sp = " ";
void nk() { cout << '\n'; }
void cas(int tt) { cout << "Case #" << tt << ":" << sp; }
const int I_max = INT_MAX;
const long long int L_max = 1e18 + 5, mod = 1000000007, MOD = 1e9 + 7;
bool rev(int a, int b) { return a >= b; }
long long int GCD(long long int arr, long long int b) {
  return ((!b) ? arr : GCD(b, arr % b));
}
long long int LCM(long long int arr, long long int b) {
  return arr / (GCD(arr, b)) * b;
}
long long int nCr(long long int n, long long int r) {
  if (n < r) return 0;
  if (r == 0) return 1;
  return n * nCr(n - 1, r - 1) / r;
}
long long int PowMod(long long int bs, long long int ex, long long int M) {
  if (!ex) return 1;
  long long int p = PowMod((bs * bs) % M, ex >> 1, M);
  return (ex & 1) ? (p * bs) % M : p;
}
long long int fastpow(long long int b, long long int e) {
  if (!e) return 1;
  if (e & 1) return b * fastpow(b, e - 1);
  long long int x = fastpow(b, e / 2);
  return x * x;
}
long long int ModInverse(long long int arr) {
  return PowMod(arr, MOD - 2, MOD);
}
long long int ExtGCD(long long int arr, long long int b, long long int& x,
                     long long int& y) {
  if (!b) {
    x = 1;
    y = 0;
    return arr;
  }
  long long int r = ExtGCD(b, arr % b, y, x);
  y -= arr / b * x;
  return r;
}
long long int mult(long long int arr, long long int b) {
  return (1LL * arr * b) % MOD;
}
long long int SumOfOdd(long long int l, long long int r) {
  long long int Rsm = (r + 1) / 2;
  Rsm *= Rsm;
  l--;
  long long int Lsm = (l + 1) / 2;
  Lsm *= Lsm;
  return Rsm - Lsm;
}
long long int NoOfOdd(long long int L, long long int R) {
  long long int N = (R - L) / 2;
  if (R % 2 != 0 || L % 2 != 0) N++;
  return N;
}
long long int NoOfEven(long long int L, long long int R) {
  return ((R - L + 1) - NoOfOdd(L, R));
}
long long int fac[1000001];
void factorial() {
  long long int MOD = 1e9 + 7;
  fac[0] = 1;
  for (long long int i = 1; i < 1000001; i++)
    fac[i] = (fac[i - 1] % MOD * (i % MOD)) % MOD;
}
vector<int> Intersection(vector<int>& v1, vector<int>& v2) {
  vector<int> v3;
  sort(v1.begin(), v1.end());
  sort(v2.begin(), v2.end());
  set_intersection(v1.begin(), v1.end(), v2.begin(), v2.end(),
                   back_inserter(v3));
  return v3;
}
vector<int> Union(vector<int>& v1, vector<int>& v2) {
  vector<int> v3;
  sort(v1.begin(), v1.end());
  sort(v2.begin(), v2.end());
  set_union(v1.begin(), v1.end(), v2.begin(), v2.end(), back_inserter(v3));
  return v3;
}
template <typename T1, typename T2>
istream& operator>>(istream& in, pair<T1, T2>& a) {
  in >> a.first >> a.second;
  return in;
}
template <typename T1, typename T2>
ostream& operator<<(ostream& out, pair<T1, T2> a) {
  out << a.first << " " << a.second;
  return out;
}
template <typename T, typename T1>
T amax(T& a, T1 b) {
  if (b > a) a = b;
  return a;
}
template <typename T, typename T1>
T amin(T& a, T1 b) {
  if (b < a) a = b;
  return a;
}
void File() {}
const int Z = 2e5 + 5;
void solve() {
  string S1, S2;
  getline(cin, S1);
  getline(cin, S2);
  map<char, int> map1, map2, map3;
  for (auto i : S1) {
    if (i >= 'a' && i <= 'z') map1[i]++;
    if (i >= 'A' && i <= 'Z') map2[i]++;
  }
  for (auto i : S2) {
    if (i >= 'a' && i <= 'z') map1[i]--;
    if (i >= 'A' && i <= 'Z') map2[i]--;
  }
  for (auto i : S2) {
    if (i >= 'a' && i <= 'z' && map1[i] < 0) {
      cout << no;
      return;
    }
    if (i >= 'A' && i <= 'Z' && map2[i] < 0) {
      cout << no;
      return;
    }
  }
  cout << yes;
}
int main() {
  ios::sync_with_stdio(0);
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  int Test = 1;
  for (int T = 1; T <= Test; T++) {
    solve();
  }
  return 0;
}
