• <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>

            ACM___________________________

            ______________白白の屋
            posts - 182, comments - 102, trackbacks - 0, articles - 0
            <2010年10月>
            262728293012
            3456789
            10111213141516
            17181920212223
            24252627282930
            31123456

            常用鏈接

            留言簿(24)

            隨筆分類(332)

            隨筆檔案(182)

            FRIENDS

            搜索

            積分與排名

            最新隨筆

            最新評論

            閱讀排行榜

            評論排行榜

             

            MiYu原創, 轉帖請注明 : 轉載自 ______________白白の屋            

             

            題目地址 :

            http://acm.hdu.edu.cn/showproblem.php?pid=3082

            題目分析:

                 沒什么特殊的方法, 簡單模擬就可以了  :

             代碼 :

            代碼
            /*
            Mail to   : miyubai@gamil.com
            My Blog   : www.baiyun.me
            Link      : 
            http://www.cnblogs.com/MiYu  || http://www.shnenglu.com/MiYu
            Author By : MiYu
            Test      : 1
            Complier  : g++ mingw32-3.4.2
            Program   : HDU_3082
            Doc Name  : Simplify The Circuit
            */
            //#pragma warning( disable:4789 )
            #include <iostream>
            #include 
            <fstream>
            #include 
            <sstream>
            #include 
            <algorithm>
            #include 
            <string>
            #include 
            <set>
            #include 
            <map>
            #include 
            <utility>
            #include 
            <queue>
            #include 
            <stack>
            #include 
            <list>
            #include 
            <vector>
            #include 
            <cstdio>
            #include 
            <cstdlib>
            #include 
            <cstring>
            #include 
            <cmath>
            #include 
            <ctime>
            using namespace std;
            char str[110];
            char *tok;
            int main ()
            {
                
            int T;
                scanf ( 
            "%d",&T );
                
            while ( T -- ) {
                    
            int N;
                    
            double res = 0;
                    scanf ( 
            "%d"&N );
                    
            for ( int i = 1; i <= N; ++ i ) {
                        scanf ( 
            "%s", str );
                        tok 
            = strtok ( str, "-" );
                        
            int t = atoi ( tok );
                        
            int r = t;
                        
            while ( tok = strtok ( NULL, "-" ) ) {
                            t 
            = atoi ( tok );
                            r 
            += t;
                        }
                        res 
            += 1.0 / r;
                    }
                    printf ( 
            "%.2lf\n"1.0 / res );
                }
                
            return 0;
            }

             

            久久久久国产亚洲AV麻豆| 欧美成人免费观看久久| 国产精品gz久久久| 亚洲а∨天堂久久精品9966| 久久精品国产亚洲AV影院| 99久久精品午夜一区二区 | 久久久免费精品re6| 97久久超碰国产精品2021| 久久久精品久久久久久 | 亚洲国产精品无码久久一线 | 久久亚洲电影| 久久精品国产网红主播| 欧美性大战久久久久久| 久久人人爽人人爽人人片av高请 | 中文字幕久久精品无码| 91精品国产91热久久久久福利| 99久久精品免费看国产一区二区三区 | 久久久久亚洲AV成人网人人网站| 国产韩国精品一区二区三区久久| 超级97碰碰碰碰久久久久最新| 91久久精品国产91性色也| 人妻精品久久久久中文字幕69 | 囯产精品久久久久久久久蜜桃| 久久e热在这里只有国产中文精品99| 97热久久免费频精品99| 77777亚洲午夜久久多喷| 久久精品国产一区二区三区不卡| 狠狠色婷婷综合天天久久丁香 | 亚洲级αV无码毛片久久精品| 久久亚洲中文字幕精品一区四 | 久久久久亚洲AV无码专区网站| 狠狠干狠狠久久| 精品久久久久久综合日本| 亚洲精品国产字幕久久不卡| 国产精品久久久久久久人人看| 精品无码久久久久久国产| 亚洲精品高清国产一久久| 亚洲狠狠久久综合一区77777| 丁香久久婷婷国产午夜视频| 久久精品国产免费| 久久这里只有精品久久|