• <ins id="pjuwb"></ins>
    <blockquote id="pjuwb"><pre id="pjuwb"></pre></blockquote>
    <noscript id="pjuwb"></noscript>
          <sup id="pjuwb"><pre id="pjuwb"></pre></sup>
            <dd id="pjuwb"></dd>
            <abbr id="pjuwb"></abbr>

            uva :: Programming Challenges :: Chapter 2

             1 /* 
             2  * File:   10038.cpp
             3  * Author: GongZhi
             4  * Problem: http://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&category=30&page=show_problem&problem=979
             5  * Created on 2009年7月27日, 上午1:10
             6  */
             7 
             8 #include <stdlib.h>
             9 #include <string.h>
            10 #include <iostream>
            11 #include <string>
            12 #include <vector>
            13 #include <map>
            14 #include <queue>
            15 using namespace std;
            16 
            17 /*
            18  *
            19  */
            20 int a[4000];
            21 char mark[4000];
            22 
            23 int main() {
            24     int n, i, t, f;
            25     while (scanf("%d"&n) != EOF) {
            26         f = 1;
            27         for (i = 0; i < n; i++)scanf("%d"&a[i]);
            28         memset(mark, 0sizeof (mark));
            29         for (i = 1; i < n; i++) {
            30             t = a[i] - a[i - 1];
            31             if (t < 0)t = -t;
            32             if (t >= n)f = 0;
            33             if (!f)break;
            34             if(mark[t])f=0;
            35             mark[t]=1;
            36             if (!f)break;
            37         }
            38         if(f)printf("Jolly\n");
            39         else printf("Not jolly\n");
            40     }
            41     return 0;
            42 }
            43 
            44 

            posted on 2009-07-27 01:17 gong 閱讀(1101) 評論(0)  編輯 收藏 引用

            <2009年7月>
            2829301234
            567891011
            12131415161718
            19202122232425
            2627282930311
            2345678

            導航

            統計

            常用鏈接

            留言簿(6)

            隨筆檔案

            搜索

            積分與排名

            最新評論

            閱讀排行榜

            評論排行榜

            久久精品国产黑森林| 狠狠色婷婷久久一区二区| 久久久国产精品| 7777精品久久久大香线蕉| 国产精品成人99久久久久 | 色综合久久最新中文字幕| 精品水蜜桃久久久久久久| 午夜久久久久久禁播电影| 色偷偷久久一区二区三区| 久久精品不卡| 久久国产精品-国产精品| 伊人色综合九久久天天蜜桃| 国产99久久久国产精品~~牛| 久久久久国产一区二区三区| AV无码久久久久不卡蜜桃| 久久国产成人亚洲精品影院| 99久久超碰中文字幕伊人| 精品国产乱码久久久久久呢| 久久人人爽人人精品视频| 久久精品国产亚洲av日韩| 久久国语露脸国产精品电影| 人妻丰满?V无码久久不卡| 久久精品中文字幕第23页| 国产69精品久久久久9999| 18岁日韩内射颜射午夜久久成人| 久久国产色AV免费观看| 77777亚洲午夜久久多喷| 色偷偷88欧美精品久久久| 久久久国产一区二区三区| 久久久精品午夜免费不卡| 人妻丰满AV无码久久不卡| 久久久亚洲裙底偷窥综合| 久久婷婷五月综合色奶水99啪| 狠狠精品久久久无码中文字幕| 午夜视频久久久久一区| 久久久久久久亚洲精品| 久久精品亚洲乱码伦伦中文| 久久精品视频91| 久久久国产打桩机| 99精品国产免费久久久久久下载| 国内精品九九久久久精品|