#include
using namespace std;
struct Rational
{
int n;
int d;
};
int main()
{
char op;
struct Rational raleft;
cin>>raleft.n>>op>>raleft.d;
struct Rational raright;
cin>>raright.n>>op>>raright.d;
if(raleft.n*raright.d > raright.n * raleft.d)
cout<< raleft.n<<"/"<"<
if(raleft.n*raright.d == raright.n * raleft.d)
cout<< raleft.n<<"/"<
if(raleft.n*raright.d < raright.n * raleft.d)
cout<< raleft.n<<"/"<
return 0;
}