#include #include using namespace std; int main() { string ver_K,ver_N; cin>>ver_K; cin>>ver_N; if(ver_K.substr(0,ver_K.find(".")) < ver_N.substr(0,ver_N.find("."))){ cout<<"NO"< ver_N.substr(0,ver_N.find("."))){ cout<<"YES"< ver_N.substr(ver_N.find(".")+1,ver_N.rfind(".")-ver_N.find("."))){ cout<<"YES"< ver_N.substr(ver_N.rfind(".")+1)){ cout<<"YES"<