首页 > 代码库 > AC日记——Is it rated? codeforces 807a

AC日记——Is it rated? codeforces 807a

Is it rated?

 

思路:

  水题;

 

代码:

#include <cstdio>#include <cstring>using namespace std;int n,a[1001],b[1001],last=5000;int main(){    scanf("%d",&n);    for(int i=1;i<=n;i++)    {        scanf("%d%d",&a[i],&b[i]);        if(a[i]!=b[i])        {            printf("rated");            return 0;        }    }    for(int i=2;i<=n;i++)    {        if(a[i]>a[i-1])        {            printf("unrated");            return 0;        }    }    printf("maybe");    return 0;}

 

AC日记——Is it rated? codeforces 807a