码迷,mamicode.com
首页 > 其他好文 > 详细

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

时间:2017-05-11 19:32:39      阅读:95      评论:0      收藏:0      [点我收藏+]

标签:++   pre   水题   string   bsp   str   思路   test   cstring   

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

标签:++   pre   水题   string   bsp   str   思路   test   cstring   

原文地址:http://www.cnblogs.com/IUUUUUUUskyyy/p/6842177.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!