#include<bits/stdc++.h> using namespace std; int main() { int a,b,c,d,k,n; double m,x; scanf("%d",&n); scanf("%d%d",&a,&b); m=(double)b/(double)a;//double(a)/double(b); for(int i=2;i<=n;i++){ scanf("%d%d",&c,&d); x=(double)d/(double)c; if(x>=m-0.05&&x<=m+0.05)cout<<"same"<<" "; else if(x<m-0.05)cout<<"worse"<<" "; else cout<<"better"<<" ";} return 0; }