#include int main(){ std::cin.tie(nullptr); std::ios::sync_with_stdio(false); int A, B; std::cin >> A >> B; bool ok = true; while(A > 0 || B > 0){ if(A % 10 < B % 10){ ok = false; break; } A /= 10; B /= 10; } if(ok){ std::cout << "Yes" << std::endl; }else{ std::cout << "No" << std::endl; } }