• <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
            Tha task of this problem is to count the number of words of one line.
            My solution is to insert a space into the beginning of the line.
            Here is my code:
            #include<stdio.h>
            #include
            <iostream>
            #include
            <string>
            using namespace std;
            bool letter(char c)
            {
                
            if((c>='a'&&c<='z')||(c>='A'&&c<='Z'))
                    
            return true;
                
            return false;
            }

            int ans;
            string s;

            int main()
            {
                
            /*
                freopen("data.in","r",stdin);
                freopen("data.out","w",stdout);
                //
            */

                
            while(getline(cin,s))
                {
                    ans
            =0;
                    s.insert(
            0," ");
                    
            for(int i=0;i<s.length()-1;i++)
                        
            if(!letter(s[i])&&letter(s[i+1]))
                            ans
            ++;
                    cout
            <<ans<<endl;
                }
            return 0;
            }
            posted on 2011-01-23 16:51 lee1r 閱讀(439) 評論(0)  編輯 收藏 引用 所屬分類: 題目分類:基礎/模擬
            伊人久久亚洲综合影院| 国产精品久久久久久福利漫画| 99久久成人18免费网站| 国产2021久久精品| 一本久久综合亚洲鲁鲁五月天亚洲欧美一区二区 | 伊人色综合久久天天| 久久亚洲电影| 国产成人精品综合久久久久| 欧美大香线蕉线伊人久久| 91精品国产高清久久久久久91| 欧美性大战久久久久久| 一本色道久久88精品综合| 国产亚洲欧美成人久久片| 久久夜色精品国产| 99久久精品国产免看国产一区| 国产免费久久久久久无码| 亚洲AV无一区二区三区久久 | 国产精品VIDEOSSEX久久发布| 久久天天躁狠狠躁夜夜不卡| 久久精品国产亚洲AV香蕉| 久久精品亚洲欧美日韩久久| 精品永久久福利一区二区| 污污内射久久一区二区欧美日韩 | 国产精品久久自在自线观看| 中文字幕亚洲综合久久菠萝蜜| 精品蜜臀久久久久99网站| 欧美精品国产综合久久| 久久久精品人妻无码专区不卡| 国产韩国精品一区二区三区久久| 亚洲精品WWW久久久久久| 国产精品久久久99| 国产亚洲色婷婷久久99精品91| 久久国产欧美日韩精品| 亚洲精品乱码久久久久久蜜桃图片 | 久久精品国产精品亜洲毛片| 久久精品aⅴ无码中文字字幕不卡| 久久丫忘忧草产品| 99久久综合国产精品免费| 中文精品99久久国产 | 中文字幕精品无码久久久久久3D日动漫 | 久久综合亚洲色HEZYO国产|