• <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
            超簡單題。
            以下是我的代碼:
            #include <cstdio>
            #include 
            <cmath>
            using namespace std;

            const double eps = 1e-8;

            double d ( double x1, double y1, double x2, double y2 )
            {
                
            return ( x1 - x2 ) * ( x1 - x2 ) + ( y1 - y2 ) * ( y1 - y2 );
            }

            int main ()
            {
            #ifndef ONLINE_JUDGE
                freopen ( 
            "data.in""r", stdin );
            #endif
                
                
            int n;
                
            double x1, y1, x2, y2, x, y, ansx, ansy;
                
            bool found;
                
                
            while ( scanf( "%d%lf%lf%lf%lf"&n, &x1, &y1, &x2, &y2 ) == 5 )
                {
                    found 
            = false;
                    
            for ( int i = 1; i <= n; i++ )
                    {
                        scanf ( 
            "%lf%lf"&x, &y );
                        
            if ( found )
                            
            continue;
                        
            if ( 4 * d ( x1, y1, x, y ) <= d ( x2, y2, x, y ) )
                        {
                            found 
            = true;
                            ansx 
            = x;
                            ansy 
            = y;
                        }
                    }
                    
                    
            //printf ( "%f\n", (double)20000*20000*2 );
                    
                    
            if ( !found )
                        printf ( 
            "The gopher cannot escape.\n" );
                    
            else
                        printf ( 
            "The gopher can escape through the hole at (%.3f,%.3f).\n", ansx, ansy );
                }
                
                
            return 0;
            }
            posted on 2011-09-08 00:11 lee1r 閱讀(650) 評論(1)  編輯 收藏 引用 所屬分類: 題目分類:基礎/模擬

            FeedBack:
            # re: UVa 10310 Dog and Gopher
            2011-09-08 03:13 | getchar
            還沒睡阿  回復  更多評論
              
            老司机国内精品久久久久| 日本国产精品久久| 伊人久久大香线焦AV综合影院| 综合久久一区二区三区| 久久精品中文无码资源站| 国产精品久久久福利| 久久精品国产欧美日韩| 色欲久久久天天天综合网| 91精品国产综合久久香蕉| 国产99久久久国产精品小说| 国产精品久久久久久久久免费| 亚洲人成无码久久电影网站| 国产亚洲精品美女久久久| 久久精品亚洲福利| 国产亚洲欧美成人久久片| 国产精品亚洲综合久久| 久久国产精品二国产精品| www.久久热.com| 无码人妻久久久一区二区三区| 亚洲国产日韩欧美久久| 91久久国产视频| 久久九九青青国产精品| 久久综合给合久久狠狠狠97色| 久久久黄色大片| 久久人搡人人玩人妻精品首页| 久久精品国产亚洲一区二区| 亚洲AV无码久久精品成人 | 亚洲愉拍99热成人精品热久久| 青青青青久久精品国产| www久久久天天com| 久久综合精品国产二区无码| 久久婷婷五月综合色奶水99啪| 久久精品女人天堂AV麻| 99久久精品国产综合一区| 久久免费精品一区二区| 狠狠久久亚洲欧美专区| 久久免费国产精品一区二区| 99精品国产在热久久无毒不卡| 人妻精品久久久久中文字幕一冢本| 伊人久久精品无码av一区| 国产激情久久久久久熟女老人|