• <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>
            很簡單的幾何題。直接硬搞即可。


            /************************************************************************* 
            Author: WHU_GCC 
            Created Time: 2007-9-13 17:09:58 
            File Name: a.cpp 
            Description:  
            ***********************************************************************
            */
             
            #include 
            <iostream> 
            #include 
            <cmath> 
            using namespace std; 
            #define out(x) (cout<<#x<<": "<<x<<endl) 
            const int maxint=0x7FFFFFFF
            typedef 
            long long int64; 
            const int64 maxint64 = 0x7FFFFFFFFFFFFFFFLL; 
            template
            <class T>void show(T a, int n){for(int i=0; i<n; ++i) cout<<a[i]<<' '; cout<<endl;} 
            template
            <class T>void show(T a, int r, int l){for(int i=0; i<r; ++i)show(a[i],l);cout<<endl;} 

            const int maxn = 600
            const int maxm = 60

            typedef 
            struct point_t 

                
            double x, y, z; 
            }


            double dot(const point_t &a, const point_t &b) 

                
            return a.x * b.x + a.y * b.y + a.z * b.z; 
            }
             

            double len2(const point_t &a) 

                
            return a.x * a.x + a.y * a.y + a.z * a.z; 
            }
             

            double angle(const point_t &a, const point_t &b) 

                
            return abs(acos(dot(a, b) / sqrt(len2(a) * len2(b)))); 
            }
             

            int n, m; 
            point_t p[maxn]; 
            point_t t[maxm]; 
            double w[maxm]; 
            int visible[maxn]; 

            int main() 

                
            while (scanf("%d"&n), n != 0
                

                    
            for (int i = 0; i < n; i++
                        scanf(
            "%lf%lf%lf"&p[i].x, &p[i].y, &p[i].z); 
                    scanf(
            "%d"&m); 
                    
            for (int i = 0; i < m; i++
                        scanf(
            "%lf%lf%lf%lf"&t[i].x, &t[i].y, &t[i].z, &w[i]); 
                     
                    memset(visible, 
            0sizeof(visible)); 
                    
            for (int i = 0; i < n; i++
                        
            for (int j = 0; j < m; j++
                            
            if (angle(p[i], t[j]) < w[j]) 
                                visible[i] 
            = 1
                     
                    
            int cnt = 0
                    
            for (int i = 0; i < n; i++
                        
            if (visible[i]) cnt++
                    printf(
            "%d\n", cnt); 
                }
             
                
            return 0
            }
             
            posted on 2007-09-15 20:25 Felicia 閱讀(388) 評論(0)  編輯 收藏 引用 所屬分類: 計算幾何
             
            99久久99久久久精品齐齐| 欧美性猛交xxxx免费看久久久| 26uuu久久五月天| 国产精品久久久久影院色| 久久狠狠高潮亚洲精品| 久久亚洲电影| 欧美激情精品久久久久| 精品国产乱码久久久久久呢| 国产AV影片久久久久久| 99久久国产亚洲高清观看2024| 丁香五月网久久综合| 狠狠狠色丁香婷婷综合久久俺| 久久精品人成免费| 国产一区二区精品久久| 国产ww久久久久久久久久| 久久99精品久久久久久秒播| 国产99久久九九精品无码| 久久精品国产福利国产琪琪| 国内精品久久久久久久亚洲| 久久久久亚洲AV无码专区网站 | 久久永久免费人妻精品下载| 亚洲级αV无码毛片久久精品| 久久久婷婷五月亚洲97号色| 国内精品久久久久久野外| 亚洲国产成人久久精品影视| 国产呻吟久久久久久久92| 免费精品国产日韩热久久| 伊人久久大香线蕉AV色婷婷色| 久久久精品2019免费观看| 亚洲天堂久久精品| 亚洲精品国产自在久久| 欧洲成人午夜精品无码区久久 | 国产三级观看久久| 91麻豆国产精品91久久久| 欧美午夜精品久久久久免费视| 久久精品国产秦先生| 欧美粉嫩小泬久久久久久久 | 国产激情久久久久影院小草 | 久久久久人妻一区精品色| 久久综合久久久| 久久精品国产99国产精品亚洲 |