• <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原創(chuàng), 轉(zhuǎn)帖請注明 : 轉(zhuǎn)載自 ______________白白の屋            

             

            題目地址 :

            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://m.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;
            }

             

            国产999精品久久久久久| 久久99亚洲网美利坚合众国| 久久成人永久免费播放| 亚洲AⅤ优女AV综合久久久| 亚洲午夜久久久影院伊人| 久久国产精品77777| 久久久精品久久久久久| 日韩久久久久久中文人妻| 亚洲国产天堂久久综合网站| 国内精品伊人久久久久777| 久久夜色精品国产亚洲| 中文字幕热久久久久久久| 精品国产青草久久久久福利| 久久综合亚洲欧美成人| 亚洲午夜福利精品久久| 久久91精品国产91久久小草| 久久人做人爽一区二区三区| 99久久综合狠狠综合久久| 亚洲国产欧洲综合997久久| 精品国产综合区久久久久久| 97精品国产91久久久久久| 一本一道久久a久久精品综合 | 久久伊人精品青青草原高清| 久久国语露脸国产精品电影| 久久久无码精品亚洲日韩软件| 91精品国产91久久综合| 色婷婷综合久久久久中文| 亚洲欧美久久久久9999| 久久精品国产国产精品四凭| 91精品国产高清久久久久久91| 久久99精品久久久久久hb无码| 久久亚洲AV无码精品色午夜麻豆| 久久综合精品国产一区二区三区| 国产成人99久久亚洲综合精品| 777米奇久久最新地址| 久久国产高潮流白浆免费观看| 久久精品国产久精国产思思| 久久99精品国产自在现线小黄鸭 | 婷婷久久综合九色综合绿巨人| 亚洲国产精品久久久久婷婷老年| 久久综合狠狠综合久久激情 |