#include using namespace std; using Int = long long; //INSERT ABOVE HERE signed main(){ string s,t,x,y; char c; cin>>s>>x>>c>>t>>y>>c; if(x==y){ cout<<-1<y; return x.size()>y.size(); }; cout<<(calc(x,y)?s:t)<