#include <bits/stdc++.h> using namespace std; int main(int argc, char** argv) { int n,c = 0; double x,y,a,b; cin>>n; cin>>a>>b; string shuchu[n-1]; x=b/a; for(int z=0;z<n-1;z++){ cin>>a>>b; y=b/a; if(y-x>0.05){ shuchu[c] = "better"; c++; }else if(x-y>0.05){ shuchu[c] = "wores"; c++; }else{ shuchu[c] = "same"; c++; } } for(int i=0;i<c;i++){ cout<<shuchu[i]<<endl; } return 0; }
标签:shuchu,int,1072,cin,c++,0.05 From: https://www.cnblogs.com/hanxuyao/p/17112379.html