#include #include #include using namespace std; int main() { string a, b; cin >> a >> b; for (auto i = a.begin() ; i != a.end() ; i++) { for (auto k = b.begin(); k != b.end(); k++) { if (*i == *k) { b.erase(k); break; } } } if (b.length() == 0) { cout << "YES" << endl; } else { cout << "NO" << endl; } return 0; }