• <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>
            voip
            風的方向
            厚德致遠,博學敦行!
            posts - 52,comments - 21,trackbacks - 0
                           有時候失去的總比得到的多!

            Description

            The Double Seventh Festival, on the 7th day of the 7th lunar month, is a traditional festival full of romance. On that day, the God of the Love came to the digital kingdom, and annunciated to the people:

            Notification


            Do you want to know who is your fere? You can find him or her by this means:
            Please add all the factors of your ID-Card-Number, and you can find this is your fere's
            ID-Card-Number.


            The factors of a numer N is the numbers,they being small than the number N ,and can being divided exactly by the number N.
            For example, the number 12 has the factors, such as 1,2,3,4,6.

             

            Input

            The fist line is the number T (1 <= T <= 500000), indicated the number of the test cases.
            The next T lines, each line has one integer N( 1 <= N <= 500000), meaning the ID-Card-Number.

            Output

            For each test case, you should output the fere's ID-Card-Number on a line.

            Sample Input

            3
            2
            10
            20
            

             

            Sample Output

            1
            8
            22
                  這個題目在我剛開始接觸ACM的時候做出來最有成就的一個!求各因子之和!
            代碼如下:
            #include<cstdio>
            int main()
            {
                
            int i,j,n,m,sum;
                scanf(
            "%d",&n);
                
            for(i=0;i<n;i++)
                
            {
                    sum
            =0;
                    scanf(
            "%d",&m);
                    
            for(j=1;j*j<=m;j++)
                    
            {
                        
            if(m%j==0)
                        
            {
                            sum
            =sum+j+m/j;
                        }

                        
            if(j*j==m)
                            sum
            -=j;
                    }

                    printf(
            "%d\n",sum-m);
                }

                
            return 0;
            }

            posted on 2010-09-06 09:34 jince 閱讀(1049) 評論(0)  編輯 收藏 引用 所屬分類: Questions
            哈哈哈哈哈哈
            国产香蕉97碰碰久久人人| 国内精品久久久久久野外| 精品一久久香蕉国产线看播放| 国产精品久久久久乳精品爆| 久久综合丁香激情久久| 久久国产精品免费| 无码人妻久久一区二区三区 | 精品久久久久久无码中文字幕| 久久久久成人精品无码| 精品久久久久久中文字幕大豆网| 狠狠久久综合| 人妻精品久久久久中文字幕一冢本| 精品国际久久久久999波多野 | 亚洲熟妇无码另类久久久| 久久香蕉一级毛片| 久久精品国产99国产精品导航 | 狠狠综合久久综合中文88| 中文精品99久久国产| 亚洲午夜精品久久久久久人妖| 综合久久给合久久狠狠狠97色| 日韩一区二区久久久久久 | 久久精品九九亚洲精品天堂| 欧美久久综合九色综合| 99久久人人爽亚洲精品美女| 精品一二三区久久aaa片| 久久精品国产欧美日韩| 韩国无遮挡三级久久| 久久亚洲欧美国产精品| 久久精品国产亚洲av麻豆图片 | 久久国产高清字幕中文| 亚洲第一极品精品无码久久| 中文字幕无码av激情不卡久久| 精品熟女少妇aⅴ免费久久| 久久99精品国产麻豆宅宅| 午夜不卡久久精品无码免费| 伊人久久大香线蕉av一区| 超级碰碰碰碰97久久久久| 久久无码人妻精品一区二区三区| 国产午夜福利精品久久| 精品水蜜桃久久久久久久| 久久最新免费视频|