• <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>
            心如止水
            Je n'ai pas le temps
            posts - 400,comments - 130,trackbacks - 0
            RE一次,WA兩次,結(jié)果是因?yàn)樘峤诲e(cuò)了題目。
            以下是我的代碼:
            #include<iostream>
            #include
            <sstream>
            #include
            <vector>
            #include
            <string>
            #include
            <algorithm>
            #include
            <cstdio>
            using namespace std;

            struct Type
            {
                Type():AC(
            false),tried(0) {}
                
                
            bool AC;
                
            int tried,AC_time;
            };

            struct Type2
            {
                Type2(
            int aa,int bb,int cc):id(aa),solved(bb),total_time(cc) {}
                
                
            int id;
                
            int solved;
                
            int total_time;
            };
            bool operator<(const Type2 &a,const Type2 &b)
            {
                
            return ((a.solved>b.solved) ||
                        (a.solved
            ==b.solved && a.total_time<b.total_time) ||
                        (a.solved
            ==b.solved && a.total_time==b.total_time && a.id<b.id));
            }

            int main()
            {
            #ifndef ONLINE_JUDGE
                freopen(
            "data.in","r",stdin);
            #endif
                
                
            int T;
                scanf(
            "%d",&T);
                cin.
            get();cin.get();
                
                
            bool first_case(true);
                
            while(T--)
                {
                    
            if(first_case)
                        first_case
            =false;
                    
            else
                        printf(
            "\n");
                    
                    Type r[
            107][17];
                    
            bool be[107]={false};
                    
                    
            string in;
                    
            while(getline(cin,in&& !in.empty())
                    {
                        
            int id,prob,tm;
                        
            char state;
                        istringstream(
            in)>>id>>prob>>tm>>state;
                        
                        be[id]
            =true;
                        
            if(state=='R' || state=='U' || state=='E' || r[id][prob].AC)
                            
            continue;
                        
            if(state=='C')
                        {
                            r[id][prob].AC
            =true;
                            r[id][prob].AC_time
            =tm+20*r[id][prob].tried;
                        }
                        
            else
                            r[id][prob].tried
            ++;
                    }
                    vector
            <Type2> a;
                    
            for(int i=1;i<=100;i++)
                        
            if(be[i])
                        {
                            
            int t1(0),t2(0);
                            
            for(int j=1;j<=9;j++)
                                
            if(r[i][j].AC)
                                {
                                    t1
            ++;
                                    t2
            +=r[i][j].AC_time;
                                }
                            a.push_back(Type2(i,t1,t2));
                        }
                    sort(a.begin(),a.end());
                    
                    
            for(int i=0;i<a.size();i++)
                        printf(
            "%d %d %d\n",a[i].id,a[i].solved,a[i].total_time);
                }
                
                
            return 0;
            }
            posted on 2011-09-06 14:08 lee1r 閱讀(408) 評(píng)論(0)  編輯 收藏 引用 所屬分類: 題目分類:基礎(chǔ)/模擬
            久久久精品国产sm调教网站| 久久精品免费大片国产大片| 国产成人香蕉久久久久| 亚洲国产精品一区二区久久| 国产亚洲婷婷香蕉久久精品| 99久久国产综合精品网成人影院 | 蜜臀av性久久久久蜜臀aⅴ麻豆 | 午夜欧美精品久久久久久久| 亚洲va久久久噜噜噜久久| 亚洲一区精品伊人久久伊人| 久久www免费人成看片| 99精品久久精品| 久久这里只有精品视频99| 亚洲精品国精品久久99热一| 怡红院日本一道日本久久 | 久久精品国产99国产精品导航| 久久久久99精品成人片| 久久久黄片| 久久久久久国产精品美女| 狠狠综合久久AV一区二区三区| 久久99精品久久久久久hb无码| 久久高清一级毛片| 麻豆成人久久精品二区三区免费| 国产成人久久精品一区二区三区 | 久久精品国产亚洲AV麻豆网站| 韩国无遮挡三级久久| 久久国产成人午夜aⅴ影院| 久久综合伊人77777麻豆| 精品久久久久久久久免费影院| 免费国产99久久久香蕉| 久久这里只有精品首页| 久久久无码人妻精品无码| 亚洲嫩草影院久久精品| 久久精品极品盛宴观看| 精品永久久福利一区二区| 久久精品国产福利国产琪琪| 2021国产精品午夜久久| 伊人久久综合热线大杳蕉下载| 精品国产日韩久久亚洲| 色综合久久88色综合天天| 亚洲第一极品精品无码久久 |