#include #include using namespace std; int main(){ string a, b; cin>> a>> b; int len = a.size(); for(int i=0; ia[j]){ swap(a[i], a[j]); } if(b[i]>b[j]){ swap(b[i], b[j]); } } } if(a==b){ cout<< "YES"<< endl; }else{ cout<< "NO"<< endl; } return 0; }