#include<bits/stdc++.h>

using namespace std;

int main(){
    long long  A,B,H,W;
    cin >> A >> B;
    cin >> H >> W;
    long long nonrotate = min(B * B * H * H,A * A * W * W);
    long long rotate = min(A * A * H * H,B * B * W * W);
    if(nonrotate > rotate){
        cout << "Non-rotating" << endl;
    }
    else if(rotate > nonrotate){
        cout << "Rotating" << endl;
    }
    else{
        cout << "Same" << endl;
    }
    return 0;
}