锘??xml version="1.0" encoding="utf-8" standalone="yes"?>国内精品久久久久久麻豆,看全色黄大色大片免费久久久 ,久久精品国产免费观看三人同眠http://www.shnenglu.com/xiaowugui/category/4110.html鍦ㄦⅵ鎯崇殑閬撹礬涓婅繕鑳借蛋澶氳繙zh-cnTue, 24 Apr 2012 22:47:36 GMTTue, 24 Apr 2012 22:47:36 GMT60涓轟粈涔堝鍒舵瀯閫犲嚱鏁扮殑鍙傛暟蹇呴』涓哄紩鐢?/title><link>http://www.shnenglu.com/xiaowugui/archive/2012/04/23/172397.html</link><dc:creator>灝忎箤榫?/dc:creator><author>灝忎箤榫?/author><pubDate>Sun, 22 Apr 2012 16:21:00 GMT</pubDate><guid>http://www.shnenglu.com/xiaowugui/archive/2012/04/23/172397.html</guid><wfw:comment>http://www.shnenglu.com/xiaowugui/comments/172397.html</wfw:comment><comments>http://www.shnenglu.com/xiaowugui/archive/2012/04/23/172397.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.shnenglu.com/xiaowugui/comments/commentRss/172397.html</wfw:commentRss><trackback:ping>http://www.shnenglu.com/xiaowugui/services/trackbacks/172397.html</trackback:ping><description><![CDATA[涓轟粈涔堝鍒舵瀯閫犲嚱鏁扮殑鍙傛暟蹇呴』涓哄紩鐢ㄥ憿錛屽師鍥犲涓嬶細(xì)<br /><div><div><p>   Because if it's not by reference, it's by value. To do that you make a copy, and to do that you call the copy constructor. But to do that, we need to need to make a new value, so we call the copy constructor, and so on...</p> <p>(You would have infinite recursion because "to make a copy, you need to make a copy".)</p> </div></div>鏉ユ簮錛?br /><div>http://stackoverflow.com/questions/2685854/why-should-the-copy-constructor-accept-its-parameter-by-reference-in-c</div><br />鑰佸繕璁幫紝涓句釜渚嬪瓙涔熻鏇村ソ鐞嗚В錛?br /><br /><div style="background-color:#eeeeee;font-size:13px;border:1px solid #CCCCCC;padding-right: 5px;padding-bottom: 4px;padding-left: 4px;padding-top: 4px;width: 98%;word-break:break-all"><!--<br /><br />Code highlighting produced by Actipro CodeHighlighter (freeware)<br />http://www.CodeHighlighter.com/<br /><br />--><span style="color: #008000; ">//</span><span style="color: #008000; ">鍒涘緩Type綾誨瀷鐨勫璞</span><span style="color: #008000; "><br /></span><span style="color: #000000; ">Type a;<br /><br /></span><span style="color: #008000; ">//</span><span style="color: #008000; ">瀵筧鐨勫璞″唴閮ㄦ暟鎹垚鍛樿祴鍊?/span><span style="color: #008000; "><br /></span><span style="color: #000000; "><img src="http://www.shnenglu.com/Images/dot.gif" alt="" /><br /><br /></span><span style="color: #008000; ">// 璋冪敤澶嶅埗鏋勯犲嚱鏁板垱寤哄璞<br /></span><span style="color: #000000; ">Type b( a )<br /></span></div><br />鐢變簬b鐨勫鍒舵瀯閫犲嚱鏁扮殑鍙傛暟琚畾涔変負(fù)鍊間紶閫掞紝閭d箞棣栧厛浼?xì)鍒涘晦Z竴涓猅ype鐨勪復(fù)鏃跺彉閲忥紝鍋囪涓簍emp1錛岀劧鍚庡啀浼犻掔粰b鐨勫鍒舵瀯閫犲嚱鏁?br /><br /><div style="background-color: #eeeeee; font-size: 13px; border: 1px solid #cccccc; padding: 4px 5px 4px 4px; width: 98%;"><!--<br /><br />Code highlighting produced by Actipro CodeHighlighter (freeware)<br />http://www.CodeHighlighter.com/<br /><br />--><span style="color: #000000;">Type temp1( a )<br /></span></div><br />鐢變簬temp1鐨勫鍒舵瀯閫犲嚱鏁扮殑鍙傛暟琚畾涔変負(fù)鍊間紶閫掞紝閭d箞棣栧厛浼?xì)鍒涘晦Z竴涓猅ype鐨勪復(fù)鏃跺彉閲忥紝鍋囪涓簍emp2錛岀劧鍚庡啀浼犻掔粰b鐨勫鍒舵瀯閫犲嚱鏁?br /><br /><div style="background-color:#eeeeee;font-size:13px;border:1px solid #CCCCCC;padding-right: 5px;padding-bottom: 4px;padding-left: 4px;padding-top: 4px;width: 98%;word-break:break-all"><!--<br /><br />Code highlighting produced by Actipro CodeHighlighter (freeware)<br />http://www.CodeHighlighter.com/<br /><br />--><span style="color: #000000; ">Type temp2( a )</span></div><br />綾繪帹,浼?xì)鍑虹幇temp3,temp4,...鐩磋嚦鏃犵┓澶氾紒<br /><br />鎵浠ュ鍒舵瀯閫犲嚱鏁扮殑鍙傛暟蹇呴』涓哄紩鐢?img src ="http://www.shnenglu.com/xiaowugui/aggbug/172397.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.shnenglu.com/xiaowugui/" target="_blank">灝忎箤榫?/a> 2012-04-23 00:21 <a href="http://www.shnenglu.com/xiaowugui/archive/2012/04/23/172397.html#Feedback" target="_blank" style="text-decoration:none;">鍙戣〃璇勮</a></div>]]></description></item><item><title>C璇█鑾峰彇鏂囦歡澶у皬http://www.shnenglu.com/xiaowugui/archive/2010/10/22/130863.html灝忎箤榫?/dc:creator>灝忎箤榫?/author>Fri, 22 Oct 2010 03:22:00 GMThttp://www.shnenglu.com/xiaowugui/archive/2010/10/22/130863.htmlhttp://www.shnenglu.com/xiaowugui/comments/130863.htmlhttp://www.shnenglu.com/xiaowugui/archive/2010/10/22/130863.html#Feedback1http://www.shnenglu.com/xiaowugui/comments/commentRss/130863.htmlhttp://www.shnenglu.com/xiaowugui/services/trackbacks/130863.html   鍥炴潵鏌ヤ簡涓嬶紝鍘熸潵鏄痜tell錛屾?zhèn)插墽鍟婂Q屼互鍓嶆病鐢ㄨ繃錛丮SDN涓奻tell鐨勫姛鑳藉涓嬶細(xì)Gets the current position of a file pointer銆傚啓浜嗘浠g爜嫻嬭瘯浜嗕笅錛屼唬鐮佸涓嬶細(xì)
#include <stdio.h>

int main()
{
    
long fileSize = 0;
    
    FILE
* pFile = fopen( "mm.data""r" );
    
if ( pFile == NULL )
    
{
        printf( 
"Open File Error\n" );
    }

    
else
    

        
// 灝嗘寚閽堝畾浣嶅埌鏂囦歡鏈熬
        fseek( pFile, 0L, SEEK_END );
        fileSize 
= ftell( pFile );
        
        printf( 
"file size: %ld\n", fileSize ); 
    }

    
return 0;
}


]]>
string涓殑+, =, +=http://www.shnenglu.com/xiaowugui/archive/2008/11/23/67668.html灝忎箤榫?/dc:creator>灝忎箤榫?/author>Sun, 23 Nov 2008 08:14:00 GMThttp://www.shnenglu.com/xiaowugui/archive/2008/11/23/67668.htmlhttp://www.shnenglu.com/xiaowugui/comments/67668.htmlhttp://www.shnenglu.com/xiaowugui/archive/2008/11/23/67668.html#Feedback0http://www.shnenglu.com/xiaowugui/comments/commentRss/67668.htmlhttp://www.shnenglu.com/xiaowugui/services/trackbacks/67668.html
鐪嬩竴孌電畝鍗曠殑浠g爜錛?br>

int main()

    
string s;
    s 
+= 'a';    
    s 
+= "bc"
    cout 
<< "s: " << s << endl;
        
    cout 
<< endl;
    system(
"Pause");
    
return 0;
}

瀵逛笉錛熷綋鐒跺鐨勶紒鍙傜湅basic_string.h涓殑婧愮爜錛?br>
      basic_string&
      
operator+=(const basic_string& __str) { return this->append(__str); }

      
/**
       *  @brief  Append a C string.
       *  @param s  The C string to append.
       *  @return  Reference to this string.
       
*/
      basic_string
&
      
operator+=(const _CharT* __s) { return this->append(__s); }

      
/**
       *  @brief  Append a character.
       *  @param s  The character to append.
       *  @return  Reference to this string.
       
*/
      basic_string
&
      
operator+=(_CharT __c) { return this->append(size_type(1), __c); }

涓嬮潰鐨勪唬鐮佸涓嶏紵

    string s1;    
    s1 
= 'a';    // = 涔熷畾涔変簡鍙寵竟鐨勫間負(fù)瀛楃鐨勬儏鍐?nbsp;
    cout << "s1: " << s1 << endl;
    s1 
= "bc";
    cout 
<< "s1: " << s1 << endl;

鐪嬫簮鐮侊紒

      basic_string&
      
operator=(const basic_string& __str) 
      { 
    
this->assign(__str); 
    
return *this;
      }

      
/**
       *  @brief  Copy contents of @a s into this string.
       *  @param  s  Source null-terminated string.
       
*/
      basic_string
&
      
operator=(const _CharT* __s) 
      { 
    
this->assign(__s); 
    
return *this;
      }

      
/**
       *  @brief  Set value to string of length 1.
       *  @param  c  Source character.
       *
       *  Assigning to a character makes this string length 1 and
       *  (*this)[0] == @a c.
       
*/
      basic_string
&
      
operator=(_CharT __c) 
      { 
    
this->assign(1, __c); 
    
return *this;
      }

涓嬮潰鐨勫憿

    string s2("u");
    s2 
= 'j' + s2;        
         cout 
<< "s2: " << s2 << endl;    
    s2 
= s2 + 'n';
    cout 
<< "s2: " << s2 << endl;
    s2 
= "jin " + s2;
    cout 
<< "s2: " << s2 << endl;
    s2 
= s2 + " xia";
    cout 
<< "s2: " << s2 << endl;

榪樻槸婧愮爜錛?br>
// operator+
  /**
   *  @brief  Concatenate two strings.
   *  @param lhs  First string.
   *  @param rhs  Last string.
   *  @return  New string with value of @a lhs followed by @a rhs.
   
*/
  template
<typename _CharT, typename _Traits, typename _Alloc>
    basic_string
<_CharT, _Traits, _Alloc>
    
operator+(const basic_string<_CharT, _Traits, _Alloc>& __lhs,
          
const basic_string<_CharT, _Traits, _Alloc>& __rhs)
    {
      basic_string
<_CharT, _Traits, _Alloc> __str(__lhs);
      __str.append(__rhs);
      
return __str;
    }

  
/**
   *  @brief  Concatenate C string and string.
   *  @param lhs  First string.
   *  @param rhs  Last string.
   *  @return  New string with value of @a lhs followed by @a rhs.
   
*/
  template
<typename _CharT, typename _Traits, typename _Alloc>
    basic_string
<_CharT,_Traits,_Alloc>
    
operator+(const _CharT* __lhs,
          
const basic_string<_CharT,_Traits,_Alloc>& __rhs);

  
/**
   *  @brief  Concatenate character and string.
   *  @param lhs  First string.
   *  @param rhs  Last string.
   *  @return  New string with @a lhs followed by @a rhs.
   
*/
  template
<typename _CharT, typename _Traits, typename _Alloc>
    basic_string
<_CharT,_Traits,_Alloc>
    
operator+(_CharT __lhs, const basic_string<_CharT,_Traits,_Alloc>& __rhs);

  
/**
   *  @brief  Concatenate string and C string.
   *  @param lhs  First string.
   *  @param rhs  Last string.
   *  @return  New string with @a lhs followed by @a rhs.
   
*/
  template
<typename _CharT, typename _Traits, typename _Alloc>
    inline basic_string
<_CharT, _Traits, _Alloc>
    
operator+(const basic_string<_CharT, _Traits, _Alloc>& __lhs,
         
const _CharT* __rhs)
    {
      basic_string
<_CharT, _Traits, _Alloc> __str(__lhs);
      __str.append(__rhs);
      
return __str;
    }

  
/**
   *  @brief  Concatenate string and character.
   *  @param lhs  First string.
   *  @param rhs  Last string.
   *  @return  New string with @a lhs followed by @a rhs.
   
*/
  template
<typename _CharT, typename _Traits, typename _Alloc>
    inline basic_string
<_CharT, _Traits, _Alloc>
    
operator+(const basic_string<_CharT, _Traits, _Alloc>& __lhs, _CharT __rhs)
    {
      typedef basic_string
<_CharT, _Traits, _Alloc>    __string_type;
      typedef typename __string_type::size_type        __size_type;
      __string_type __str(__lhs);
      __str.append(__size_type(
1), __rhs);
      
return __str;
    }

涔熻錛屾渶濂界殑璧勬枡灝辨槸鐪嬬湅澶存枃浠舵垨鑰呮簮鐮侊紒




]]>
涓ゆCTRL+Z鎵嶈兘涓紼嬪簭http://www.shnenglu.com/xiaowugui/archive/2008/10/26/65100.html灝忎箤榫?/dc:creator>灝忎箤榫?/author>Sun, 26 Oct 2008 08:34:00 GMThttp://www.shnenglu.com/xiaowugui/archive/2008/10/26/65100.htmlhttp://www.shnenglu.com/xiaowugui/comments/65100.htmlhttp://www.shnenglu.com/xiaowugui/archive/2008/10/26/65100.html#Feedback0http://www.shnenglu.com/xiaowugui/comments/commentRss/65100.htmlhttp://www.shnenglu.com/xiaowugui/services/trackbacks/65100.html 

#include <stdio.h>

main()
{
    
char c;
    
while (scanf("%c"&c) != EOF)
    {
        printf(
"%c", c);
    }
    
return 0;
}

 

涓孌靛緢璁╀漢涓嶇埥鐨勪唬鐮侊紝涓轟粈涔堣杈撳叆涓ゆCtrl+Z鍛€傚彧鑳借鏄疺C6.0鍜孋-Free鐨刡ug, 璋佺煡閬撲簡鍛婅瘔鎴戜竴澹般傚叾浠栦漢鐨勮璁猴細(xì)
    http://topic.csdn.net/u/20080429/22/dcd3aba2-0cad-4c56-aeb2-2be7d3b07d44.html
   


]]>
cout << &("abc") << endl瑙f瀽http://www.shnenglu.com/xiaowugui/archive/2008/09/09/61349.html灝忎箤榫?/dc:creator>灝忎箤榫?/author>Mon, 08 Sep 2008 17:27:00 GMThttp://www.shnenglu.com/xiaowugui/archive/2008/09/09/61349.htmlhttp://www.shnenglu.com/xiaowugui/comments/61349.htmlhttp://www.shnenglu.com/xiaowugui/archive/2008/09/09/61349.html#Feedback0http://www.shnenglu.com/xiaowugui/comments/commentRss/61349.htmlhttp://www.shnenglu.com/xiaowugui/services/trackbacks/61349.html ChinaUnix涓婄湅鍒版湁浜洪棶浜嗕竴涓棶棰?紼嬪簭浠g爜濡備笅:
cout << &("abc"<< endl;        // 杈撳嚭abc
cout << &(&("abc")) << endl;     // 杈撳嚭abc
cout << &(&(&("abc"))) << endl;
// 杈撳嚭abc錛屽ソ鍍忔棤璁哄湪"abc"鍓嶅姞鍑犱釜&錛岃緭鍑洪兘涓篴bc
   涓涓漢鐨勮瘎浠?
   鏁扮粍char str[]鍦ㄥ唴瀛樹腑瀛樺偍鏂瑰紡:str鍜?amp;str鏄悓涓涓?涔熷氨鏄str鏈韓鍦ㄥ唴瀛樹腑娌℃湁鍗犵敤絀洪棿,str銆?amp;str鍜?amp;str[0]鐨勫兼槸涓鏍風(fēng)殑錛屽彧鏄洿鎺ョ粰str[]鐨勬暟緇勫厓绱犲垎閰嶄簡絀洪棿銆傛寚閽坈har *str鍦ㄥ唴瀛樹腑鐨勫瓨鍌ㄦ柟寮忥細(xì)棣栧厛浼?xì)缁檚tr鍙橀噺鏈韓鍒嗛厤絀洪棿錛屼篃灝辨槸璇磗tr鍜?amp;str鐨勫艱偗瀹氭槸涓嶄竴鏍風(fēng)殑錛?amp;str灝辨槸str鐨勫湴鍧錛屽湪鎸囬拡鍒濆鍖栧悗鎵嶇粰鎸囬拡char *str鎵鎸囧悜鐨勫瓧絎︿覆鏄庣‘鐨勫垎閰嶇┖闂達(dá)紝褰撶劧榪欎釜絀洪棿鐨勯鍦板潃灝辨槸str鐨勫箋傛墍浠ユ暟緇勫拰鎸囬拡榪樻槸鏈夊尯鍒殑錛屽彧鏄紪璇戝櫒瀵規(guī)寚閽堢殑澶勭悊鏄寜鐓у鐞嗘暟緇勭殑鏂瑰紡鏉ュ鐞嗙殑銆?br>  榪欎釜璇勪環(huán)鐪熺殑鏄偅涔堟紜悧?
   鍏堝垎鏋愪唬鐮?涓変釜杈撳嚭涓鏍?鏄洜涓?鍙栧湴鍧榪愮畻絎﹀彧鑳界敤浜庡唴瀛樹腑鐨勫璞?鍗沖彉閲忓拰鏁扮粍鍏冪礌.瀹冧笉鑳戒綔鐢ㄤ簬琛ㄨ揪寮?甯擱噺鎴杛egister綾誨瀷鐨勫彉閲?The C Programming Language P93).
   閭d箞瀛楃涓插父閲忕殑榪斿洖鍊兼槸浠涔堝憿?鏄寚閽堝彉閲忓悧?涓嶅儚!鏈変漢璇?鎬庝箞涓嶅儚浜?褰撲綘鎶婁竴涓瓧絎︿覆甯擱噺浣滀負(fù)涓涓弬鏁頒紶閫掔粰鍑芥暟,鍏惰涓哄氨鍍忔寚閽堝晩.閭e氨鎯蟲兂鏁扮粍,灝嗘暟緇勫悕浼犻掔粰鍑芥暟,瀹冪殑琛屼負(fù)涔熷儚鎸囬拡鍟?鍙暟緇勫悕緇堢┒涓嶆槸鎸囬拡,鍙笉榪囦綔涓哄嚱鏁板弬鏁版椂,鍏墮鍖栦負(fù)浜嗘寚閽?鏄笉鏄儚鏁扮粍,鐨勭‘鏈夐偅縐嶅懗閬?涓嶄俊灝辯湅鐪嬩笅闈㈢殑嫻嬭瘯浠g爜:
#include <stdio.h>

main(
int argc, char *argv[])
{
    
char *p  = "xiexiu";
    
char s[] = "xiexiu";
    
    printf(
"%u\n"sizeof "xiexiu");
    printf(
"%u\n"sizeof p);
    printf(
"%u\n"sizeof s);
    
return 0;
}
   杈撳嚭緇撴灉鏃?
   7
   4
   7
   鏃㈢劧榪欐牱鐨勮瘽,閭d箞鏁扮粍鍚嶆槸鍙橀噺榪樻槸甯擱噺鍛?鏁扮粍鍚嶅疄璐ㄤ笂鏄繖涓暟緇勭殑棣栧湴鍧錛屼竴鏃︾郴緇熷紑杈熶簡榪欏潡鍐呭瓨錛岄偅涔堣繖涓唴瀛樼殑棣栧湴鍧灝變笉鑳芥敼鍙橈紝鎵浠ワ紝瀵規(guī)暟緇勫悕鐨勮祴鍊艱偗瀹氭槸涓嶅厑璁哥殑銆傛暟緇勫悕絳夊悓浜庡父閲忥紝浣嗘槸榪樻湁娌℃湁鏁扮粍鍚嶅氨鏄父閲忕殑璇存硶銆傝繖灝辮鏄庝簡鏁扮粍鍚嶇粷涓嶆槸鍙橀噺,褰撶劧涔熶笉鏄暟緇勫厓绱犱簡.鍥犳瀵規(guī)暟緇勫悕鍙栧湴鍧,瑕佷箞鏄湭瀹氫箟,瑕佷箞鏄潪娉曠殑.瀵瑰瓧絎︿覆甯擱噺鍙栧湴鍧,寰堝緙栬瘧鍣ㄩ兘鍙互閫氳繃,鍙槸璀﹀憡涓鐣?鍥犳瀵逛簬鏁扮粍str[],str鍜?amp;str鏄悓涓涓肩殑璇存硶鏄笉瀵?鍥犱負(fù)&str榪欎釜鏈韓涓嶅悎娉曟垨鏈畾涔夌殑.
   榪樻湁浠栬:鎵浠ユ暟緇勫拰鎸囬拡榪樻槸鏈夊尯鍒殑錛屽彧鏄紪璇戝櫒瀵規(guī)寚閽堢殑澶勭悊鏄寜鐓у鐞嗘暟緇勭殑鏂瑰紡鏉ュ鐞嗙殑銆傛暟緇勫綋鐒跺拰鎸囬拡鏈夊尯鍒簡.鏁扮粍鍚嶄笉鏄彉閲?鑰屾寚閽堟槸.緙栬瘧鍣ㄥ鎸囬拡鐨勫鐞嗘槸鎸夌収澶勭悊鏁扮粍鐨勬柟寮忔潵澶勭悊鐨勫悧?閭d箞涓轟粈涔堢敤鎸囬拡緙栧啓鐨勭▼搴忔瘮鏁扮粍鐨勫揩?
   The C Programming Language P98:鍦ㄨ綆楁暟緇勫厓绱燼[i]鐨勫兼椂,C璇█瀹為檯涓婂厛灝嗗叾杞崲涓?(a+i)鐨勫艦寮?鐒跺悗鍐嶈繘琛屾眰鍊?榪欏氨璇存槑浜嗙紪璇戝櫒瀵規(guī)暟緇勭殑澶勭悊鏄寜鐓ф寚閽堢殑鏂瑰紡鏉ュ鐞嗙殑.鍚屾椂涔熻鏄庝簡涓轟粈涔堢敤鎸囬拡緙栧啓鐨勭▼搴忔瘮鐢ㄦ暟緇勭紪鍐欑殑蹇?




]]>
C-Free瀵圭▼搴忓懡浠よ鍙傛暟*鐨勫鐞?/title><link>http://www.shnenglu.com/xiaowugui/archive/2008/09/06/61104.html</link><dc:creator>灝忎箤榫?/dc:creator><author>灝忎箤榫?/author><pubDate>Sat, 06 Sep 2008 03:42:00 GMT</pubDate><guid>http://www.shnenglu.com/xiaowugui/archive/2008/09/06/61104.html</guid><wfw:comment>http://www.shnenglu.com/xiaowugui/comments/61104.html</wfw:comment><comments>http://www.shnenglu.com/xiaowugui/archive/2008/09/06/61104.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.shnenglu.com/xiaowugui/comments/commentRss/61104.html</wfw:commentRss><trackback:ping>http://www.shnenglu.com/xiaowugui/services/trackbacks/61104.html</trackback:ping><description><![CDATA[<p>   鐢–-Free(浣跨敤榛樿鐨刴ingw緙栬瘧鍣?緙栬瘧涓涓▼搴忕殑鏃跺?鍑虹幇浜嗕竴涓彜鎬殑鐜拌薄.MS濡傛灉涓涓▼搴忔湁鍛戒護(hù)琛屽弬鏁頒笖鍛戒護(hù)琛屽弬鏁頒腑鍚湁*,鍒欑紪璇戝櫒灝變細(xì)灝?鏇挎崲涓烘湰鐩綍涓嬬殑鎵鏈夋枃浠跺悕,鑰岀敤VC++6.0鍒欎笉浼?xì)鍑虹庮C互涓婄殑鎯呭喌.</p>    嫻嬭瘯浜嗕竴鐣?鐨勭‘濡傛.紼嬪簭浠g爜濡備笅:<br> <div style="BORDER-RIGHT: #cccccc 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #cccccc 1px solid; PADDING-LEFT: 4px; FONT-SIZE: 13px; PADDING-BOTTOM: 4px; BORDER-LEFT: #cccccc 1px solid; WIDTH: 98%; WORD-BREAK: break-all; PADDING-TOP: 4px; BORDER-BOTTOM: #cccccc 1px solid; BACKGROUND-COLOR: #eeeeee"><span style="COLOR: #008000">/*</span><span style="COLOR: #008000"> 鍖呭惈澶存枃浠?nbsp;</span><span style="COLOR: #008000">*/</span><span style="COLOR: #000000"> <br>#include </span><span style="COLOR: #000000"><</span><span style="COLOR: #000000">stdio.h</span><span style="COLOR: #000000">></span><span style="COLOR: #000000"><br><br>main(</span><span style="COLOR: #0000ff">int</span><span style="COLOR: #000000"> argc, </span><span style="COLOR: #0000ff">char</span><span style="COLOR: #000000"> </span><span style="COLOR: #000000">*</span><span style="COLOR: #000000">argv[])<br>{<br>    </span><span style="COLOR: #0000ff">while</span><span style="COLOR: #000000"> (argc</span><span style="COLOR: #000000">--</span><span style="COLOR: #000000"> </span><span style="COLOR: #000000">></span><span style="COLOR: #000000"> </span><span style="COLOR: #000000">0</span><span style="COLOR: #000000">)<br>    {    <br>        printf(</span><span style="COLOR: #000000">"</span><span style="COLOR: #000000">%s\n</span><span style="COLOR: #000000">"</span><span style="COLOR: #000000">, </span><span style="COLOR: #000000">*</span><span style="COLOR: #000000">argv</span><span style="COLOR: #000000">++</span><span style="COLOR: #000000">);<br>    }<br>    </span><span style="COLOR: #0000ff">return</span><span style="COLOR: #000000"> </span><span style="COLOR: #000000">0</span><span style="COLOR: #000000">;<br>}</span></div>    鐢–-Free4.0(浣跨敤榛樿鐨刴ingw緙栬瘧鍣?緙栬瘧鎴恊xpr.exe.鐒跺悗灝嗗叾鏀劇疆浜庝竴涓枃浠跺す涓?姝ゆ椂鏂囦歡澶歸噷鍚湁涓や釜鏂囦歡:expr.exe鍜宔xpr.txt.浠庡懡浠よ鎵ц: expr.exe *,緇撴灉鏄劇ず:<br>   expr.exe<br>   expr.exe<br>   expr.txt<br><br>   鐢╒C++6.0緙栬瘧鎴恊xpr2.exe,鐒跺悗灝嗗畠縐誨埌姝ゆ枃浠跺す涓?鎵ц鍚屾牱鐨勫懡浠? expr.exe *,緇撴灉濡備笅:<br>   expr2.exe<br>   * <br><br>   濡傛灉*涓嶆槸浣滀負(fù)涓涓崟鐙殑鍙傛暟,鑰屾槸浣滀負(fù)涓涓弬鏁扮殑涓閮ㄥ垎,鎯呭喌浼?xì)鎬庢牱,鎵ц鍛戒護(hù):expr.exe 1*2,緇撴灉濡備笅:<br>   expr.exe<br>   1*2<br>   鍥犳,鍦ㄤ嬌鐢–-Free(榛樿緙栬瘧鍣╩ingw)緙栬瘧鍚湁*鍛戒護(hù)琛屽弬鏁扮殑紼嬪簭,鍔″繀灝忓績. <img src ="http://www.shnenglu.com/xiaowugui/aggbug/61104.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.shnenglu.com/xiaowugui/" target="_blank">灝忎箤榫?/a> 2008-09-06 11:42 <a href="http://www.shnenglu.com/xiaowugui/archive/2008/09/06/61104.html#Feedback" target="_blank" style="text-decoration:none;">鍙戣〃璇勮</a></div>]]></description></item><item><title>緇檌nt璧嬫渶灝忓奸棶棰?/title><link>http://www.shnenglu.com/xiaowugui/archive/2008/08/01/57775.html</link><dc:creator>灝忎箤榫?/dc:creator><author>灝忎箤榫?/author><pubDate>Fri, 01 Aug 2008 08:40:00 GMT</pubDate><guid>http://www.shnenglu.com/xiaowugui/archive/2008/08/01/57775.html</guid><wfw:comment>http://www.shnenglu.com/xiaowugui/comments/57775.html</wfw:comment><comments>http://www.shnenglu.com/xiaowugui/archive/2008/08/01/57775.html#Feedback</comments><slash:comments>0</slash:comments><wfw:commentRss>http://www.shnenglu.com/xiaowugui/comments/commentRss/57775.html</wfw:commentRss><trackback:ping>http://www.shnenglu.com/xiaowugui/services/trackbacks/57775.html</trackback:ping><description><![CDATA[<br> <div style="BORDER-RIGHT: #cccccc 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #cccccc 1px solid; PADDING-LEFT: 4px; FONT-SIZE: 13px; PADDING-BOTTOM: 4px; BORDER-LEFT: #cccccc 1px solid; WIDTH: 98%; WORD-BREAK: break-all; PADDING-TOP: 4px; BORDER-BOTTOM: #cccccc 1px solid; BACKGROUND-COLOR: #eeeeee"><span style="COLOR: #0000ff">int</span><span style="COLOR: #000000"> n </span><span style="COLOR: #000000">=</span><span style="COLOR: #000000"> </span><span style="COLOR: #000000">-</span><span style="COLOR: #000000">2147483648</span><span style="COLOR: #000000">;</span></div> <br>        濡傛綆鍗曠殑涓鍙ヤ唬鐮侊紝灞呯劧鍑虹幇浜嗚鍛婏紵-2147483648鏄?2浣峣nt綾誨瀷鍙互瀛樺偍鐨勬渶灝忔暣鍨嬪鹼紝涓轟粈涔堜細(xì)鍑洪」璀﹀憡鍛€傚湪VC++6.0鎺у埗鍙扮▼搴忎笅鍑虹幇濡備笅璀﹀憡錛歸arning C4146: unary minus operator applied to unsigned type, result still unsigned銆傚湪C-Free涓嚭鐜幫細(xì)c:55: warning: decimal constant is so large that it is unsigned銆?br><br>        涓婄綉鏌ヤ簡涓嬶紝鍙戠幇浜嗗師鍥狅細(xì)<br>        涓鍏冭礋榪愮畻絎﹀簲鐢ㄤ簬鏃犵鍙風(fēng)被鍨嬶紝緇撴灉浠嶄負(fù)鏃犵鍙風(fēng)被鍨嬨傛棤絎﹀彿綾誨瀷鍙兘淇濆瓨闈炶礋鍊鹼紝鎵浠ヤ竴鍏冭礋錛堥潪錛夊簲鐢ㄤ簬鏃犵鍙風(fēng)被鍨嬫椂閫氬父鏃犳剰涔夈傛搷浣滄暟鍜岀粨鏋滈兘鏄潪璐熺殑銆?nbsp;<br>        瀹為檯涓婏紝褰撶▼搴忓憳璇曞浘琛ㄨ揪鏈灝忔暣鏁板?2147483648 鏃訛紝鍙戠敓姝ら棶棰樸傝鍊間笉鑳藉啓涓?2147483648錛屽洜涓鴻〃杈懼紡澶勭悊鍒嗕袱涓楠わ細(xì) <br>        璁$畻鏁板瓧2147483648銆傚洜涓?147483648 澶т簬鏈澶ф暣鏁板?147483647錛屾墍浠ュ叾綾誨瀷涓嶆槸int錛岃屾槸unsigned int銆?nbsp;<br>        灝嗕竴鍏冭礋搴旂敤浜庤鍊鹼紝寰楀埌鏃犵鍙風(fēng)粨鏋滐紝璇ョ粨鏋滅宸ф槸 2147483648銆傛棤絎﹀彿綾誨瀷鐨勭粨鏋滃彲鑳藉鑷存剰澶栬涓恒傚鏋滃湪姣旇緝涓嬌鐢ㄨ緇撴灉錛屽垯鍙嬌鐢ㄦ棤絎﹀彿姣旇緝錛岃屼笉鑳藉嚭鐜板彟涓涓搷浣滄暟鏄?int 鏃躲傝繖瑙i噴浜嗕笅闈㈢殑紺轟緥紼嬪簭鍙緭鍑轟竴琛岀殑鍘熷洜銆?nbsp;<br>        棰勬湡鐨勭浜岃涓猴細(xì)1 is greater than the most negative int錛屼絾鏈緭鍑猴紝鍥犱負(fù)((unsigned int)1) > 2147483648涓哄亣銆?nbsp;<br> <div style="BORDER-RIGHT: #cccccc 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #cccccc 1px solid; PADDING-LEFT: 4px; FONT-SIZE: 13px; PADDING-BOTTOM: 4px; BORDER-LEFT: #cccccc 1px solid; WIDTH: 98%; WORD-BREAK: break-all; PADDING-TOP: 4px; BORDER-BOTTOM: #cccccc 1px solid; BACKGROUND-COLOR: #eeeeee"><span style="COLOR: #000000">#include <stdio.h><br></span><span style="COLOR: #000000"><br>main()<br>{<br><br>    check(</span><span style="COLOR: #000000">-</span><span style="COLOR: #000000">10</span><span style="COLOR: #000000">);<br>    check(</span><span style="COLOR: #000000">1</span><span style="COLOR: #000000">);<br><br>    </span><span style="COLOR: #0000ff">return</span><span style="COLOR: #000000"> </span><span style="COLOR: #000000">0</span><span style="COLOR: #000000">;<br>}<br><br><br></span><span style="COLOR: #0000ff">void</span><span style="COLOR: #000000"> check(</span><span style="COLOR: #0000ff">int</span><span style="COLOR: #000000"> i) <br>{ <br>    </span><span style="COLOR: #0000ff">if</span><span style="COLOR: #000000"> (i </span><span style="COLOR: #000000">></span><span style="COLOR: #000000"> </span><span style="COLOR: #000000">-</span><span style="COLOR: #000000">2147483648</span><span style="COLOR: #000000">)<br>    printf(</span><span style="COLOR: #000000">"</span><span style="COLOR: #000000">%d is greater than the most negative int\n</span><span style="COLOR: #000000">"</span><span style="COLOR: #000000">, i); <br>}</span></div>         <br>        杈撳嚭緇撴灉錛?br><img src="http://www.shnenglu.com/images/cppblog_com/xiaowugui/QQ.jpeg" border=0><br><br>        涓婇潰鐨勮В閲婄渷鐣ヤ簡涓浜涚粏鑺傦紝鎴戞潵琛ュ厖涓嬨傚湪if  (i > -2147483648)涓紝鐢變簬i涓篿nt綾誨瀷錛岃?2147483648涓簎nsigned int綾誨瀷錛屾墍鏈塱灝變細(xì)琚彁鍗囦負(fù)unsigned int綾誨瀷錛岃繖灝辨槸C璇█鐨勬暣鍨嬫彁鍗囥?10鎻愬崌涓簎nsigned int綾誨瀷鍚庯紝鍏跺艱偗瀹氫細(xì)澶т簬2147483648錛屽洜姝ょ涓鏉¤鍙ヤ細(xì)鎵撳嵃鍑烘潵銆傚綋鎶婃鏁存暟錛堟瘮濡傛湰瀹為獙涓殑1錛夋彁鍗囦負(fù)unsigned int綾誨瀷鏃訛紝鍏跺兼槸涓嶅彉鐨勶紝鍥犳鑲畾姣?147483648瑕佸皬錛屾墍鏈夌浜屾潯璇彞涓嶄細(xì)鎵撳嵃銆?br><br>      閭e浣曟潵瑙e喅榪欎釜鍙伓鐨勮鍛婂憿銆傜綉涓婅錛氬彲浠ラ氳繃浠?Limits.h 浣跨敤INT_MIN(涓涓畯瀹氫箟) 鏉ラ伩鍏岰4146 璀﹀憡銆侷NI_MIN瀹忔湁濡備綍鐨勯瓟鍔涳紝绔熺劧鑳藉娑堥櫎榪欎釜璀﹀憡鍛€傛墦寮婧愭枃浠朵竴鐪嬶紝鍘熸潵鏄繖鏍鳳細(xì)<br> <div style="BORDER-RIGHT: #cccccc 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #cccccc 1px solid; PADDING-LEFT: 4px; FONT-SIZE: 13px; PADDING-BOTTOM: 4px; BORDER-LEFT: #cccccc 1px solid; WIDTH: 98%; WORD-BREAK: break-all; PADDING-TOP: 4px; BORDER-BOTTOM: #cccccc 1px solid; BACKGROUND-COLOR: #eeeeee"><span style="COLOR: #0000ff">#define</span><span style="COLOR: #000000"> INT_MAX        2147483647</span><span style="COLOR: #000000"><br></span><span style="COLOR: #0000ff">#define</span><span style="COLOR: #000000"> INT_MIN        (-INT_MAX-1)</span></div> <br>        鍝︼紝鍘熸潵榪欐牱銆傚洜姝わ紝鎴戜滑鍙堝彲浠ヨ繖鏍瘋祴鍊兼渶灝忚礋鏁存暟錛?br> <div style="BORDER-RIGHT: #cccccc 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #cccccc 1px solid; PADDING-LEFT: 4px; FONT-SIZE: 13px; PADDING-BOTTOM: 4px; BORDER-LEFT: #cccccc 1px solid; WIDTH: 98%; WORD-BREAK: break-all; PADDING-TOP: 4px; BORDER-BOTTOM: #cccccc 1px solid; BACKGROUND-COLOR: #eeeeee"><img src="http://www.shnenglu.com/Images/OutliningIndicators/None.gif" align=top><span style="COLOR: #0000ff">int</span><span style="COLOR: #000000"> n </span><span style="COLOR: #000000">=</span><span style="COLOR: #000000"> </span><span style="COLOR: #000000">-</span><span style="COLOR: #000000">2147483647</span><span style="COLOR: #000000"> </span><span style="COLOR: #000000">-</span><span style="COLOR: #000000"> </span><span style="COLOR: #000000">1</span><span style="COLOR: #000000">;</span></div> <img src ="http://www.shnenglu.com/xiaowugui/aggbug/57775.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.shnenglu.com/xiaowugui/" target="_blank">灝忎箤榫?/a> 2008-08-01 16:40 <a href="http://www.shnenglu.com/xiaowugui/archive/2008/08/01/57775.html#Feedback" target="_blank" style="text-decoration:none;">鍙戣〃璇勮</a></div>]]></description></item><item><title>C/C++涓殑鏋氫婦http://www.shnenglu.com/xiaowugui/archive/2008/07/29/57423.html灝忎箤榫?/dc:creator>灝忎箤榫?/author>Tue, 29 Jul 2008 07:35:00 GMThttp://www.shnenglu.com/xiaowugui/archive/2008/07/29/57423.htmlhttp://www.shnenglu.com/xiaowugui/comments/57423.htmlhttp://www.shnenglu.com/xiaowugui/archive/2008/07/29/57423.html#Feedback2http://www.shnenglu.com/xiaowugui/comments/commentRss/57423.htmlhttp://www.shnenglu.com/xiaowugui/services/trackbacks/57423.html        鏋氫婦鍙橀噺鎻愪緵榪欑媯(gè)鏌ワ紝浠涔堟剰鎬濓紵鏋氫婦鍙橀噺浼?xì)鑷繁妫錛熷綋鐒朵笉鏄紝浣滆呬篃璁告兂璇寸▼搴忓憳鑷繁鍙互鍐欎釜紼嬪簭媯(gè)鏌ヤ粯緇欐灇涓懼彉閲忕殑鍊兼槸鍚︿負(fù)璇ユ灇涓劇殑鏈夋晥鍊箋?br>
/* 鍖呭惈澶存枃浠?nbsp;*/ 
#include 
<stdio.h>

/* 鏋氫婦綾誨瀷 */
enum months{JAN = 1, FEB};

/* 鍑芥暟鍘熷瀷 */
void enumeration(enum months m);

main()
{
    
enum months a = 2; 
    
enum months b = 50;        /* C涓笉闇瑕佸己鍒惰漿鎹負(fù)enum months綾誨瀷 */

    enum months c = JAN;

    enumeration(a);
    enumeration(b);

    
return 0;
}

/* enumeration鍑芥暟錛氭嫻嬫灇涓懼彉閲忓瓨鍌ㄧ殑鍊兼槸鍚︿負(fù)璇ユ灇涓劇殑鏈夋晥鍊?nbsp;*/
void enumeration(enum months m)
{
    
switch (m)
    {
    
case JAN:
        printf(
"JAN: %d\n", JAN);
        
break;

    
case FEB:
        printf(
"FEB: %d\n", FEB);
        
break;

    
default:
        printf(
"%d涓嶆槸璇ユ灇涓劇殑鏈夋晥鍊鹼紒\n", m);
        
break;
    }
}


鑰岃繖孌典唬鐮佸鏋滄敼涓篊++婧愭枃浠剁紪璇戯紝鍗翠笉鑳介氳繃銆傚師鍥犲涓嬶細(xì)

鏍規(guī)嵁C鏍囧噯鐨勮瀹氾紝鏋氫婦甯擱噺鐨勭被鍨嬩負(fù)int錛屾灇涓懼彉閲忕殑綾誨瀷搴旇涓巆har銆佹湁絎﹀彿鎴栨棤絎﹀彿鏁村瀷鍏煎銆傚洜姝わ紝鏋氫婦鍙橀噺鍙互鎺ュ彈 char銆佹湁絎﹀彿鎴栨棤絎﹀彿鏁村瀷鏁幫紝鑰屼笉闄愪簬浠呬粠姝ゆ灇涓劇被鍨嬫墍瀹氫箟鐨勬灇涓懼父閲忎腑鍙栧箋傜敱浜庝笂榪板師鍥狅紝鍦–瑾炶█涓棤娉曚粠瑾炴硶涓婁繚璇佹灇涓懼彉閲忓彧鑳藉湪瀹氫箟鐨勬灇涓炬垚鍛樹腑鍙栧鹼紝鍙兘鐢辯▼搴忓憳鑷韓淇濊瘉涓嶄嬌鐢ㄩ櫎鏋氫婦鎴愬憳涔嬪鐨勫箋?br>
鍏充簬閫欎竴鐐癸紝寰堝浠嬬粛C璇█鐨勪功涓婃垨鑰呰祫鏂欎笂鐨勬弿榪版槸涓嶆紜殑錛屽簲璇ュ姞浠ユ敞鎰忋?br>
浣嗘槸錛屽鏋滅粰鏋氫婦鍙橀噺璧嬫灇涓炬垚鍛樹箣澶栫殑鍊鹼紝鏈夌殑緙栬瘧鍣ㄥ彲鑳戒細(xì)瀵規(guī)浜х敓璀﹀憡錛屾湁鐨勫垯涓嶆渻銆傚洜涓鴻繖縐嶈涓轟笉榪濆弽C鏍囧噯鐨勮瀹氾紝緙栬瘧鍣ㄥ姝ゅ浣曞弽搴旈兘鏄湁閬撶悊鐨勩?br>
鐒惰屽浜嶤++鏉ヨ錛岀紪璇戝櫒浼?xì)绂佹缁欐灇鋴D鍙橀噺璧嬩簣鏋氫婦鎴愬憳涔嬪鐨勫箋傝繖鏄洜涓篊++鏄竴縐嶅己綾誨瀷璇█錛屾灇涓劇被鍨嬩笉絳夊悓浜?int 絳夊叾瀹冪被鍨嬨傝櫧鐒舵灇涓劇被鍨嬪彲浠ラ殣寮忚漿鍖栦負(fù) int 絳夌被鍨嬶紝浣嗘槸 int 絳夌被鍨嬪嵈涓嶈兘鑷姩杞寲涓烘灇涓劇被鍨嬶紝闄ら潪浣跨敤寮哄埗綾誨瀷杞寲銆傚洜姝わ紝濡傛灉涓嶄嬌鐢ㄥ己鍒剁被鍨嬭漿鍖栫殑璇濓紝緇欐灇涓懼彉閲忚祴鍊煎垯鍙兘浠庢灇涓炬垚鍛樹腑閫夋嫨銆傚浜庢灇涓劇被鍨嬭閬垮厤浣跨敤寮哄埗綾誨瀷杞崲銆傚師鍥犲涓嬶細(xì)
 
The   C++   Programming   Language涓婅:   
濡傛灉鏌愪釜鏋氫婦涓墍鏈夋灇涓懼奸潪璐?鏋氫婦鐨勮〃紺鴻寖鍥翠負(fù)[0 : 2^k-1];鍏朵腑2^K鏄嬌鎵鏈夋灇涓炬垚鍛樹綅浜庢鑼冨洿鍐呯殑鏈灝忕殑2鐨勫箓;濡傛灉鏄礋鐨?灝辨槸[-2^k : 2^k-1]銆?鍥犳瀵逛竴涓粰瀹氱殑鏁存暟鍊鹼紝濡傛灉浣跨敤寮哄埗綾誨瀷杞崲錛岃屽叾鍊煎張涓嶅湪鏋氫婦鐨勮〃紺鴻寖鍥翠互鍐咃紝鍏惰涓烘槸鏈畾涔夌殑銆?br>

// 鍖呭惈澶存枃浠?nbsp; 
#include <iostream.h>

int main()
{
    
enum months{JAN = 1, FEB, MAR};

    
//enum months a = 1;              //cannot convert from 'const int' to 'enum main::months'
    enum months a = (enum months)1;
    cout 
<< "a: " << a << endl;    //杈撳嚭: a: 1

    
enum months b = (enum months)10;
    cout 
<< "b: " << b << endl;    //杈撳嚭: b: 10 铏界劧杈撳嚭10錛屼絾緇撴灉鏄湭瀹氫箟鐨勶紝鍥犱負(fù)姝ゆ灇涓劇殑琛ㄧず鑼冨洿涓猴細(xì)0锝?

    
return 0;
}


]]>
C涓繍綆楃緇撳悎鎬?/title><link>http://www.shnenglu.com/xiaowugui/archive/2008/07/28/57373.html</link><dc:creator>灝忎箤榫?/dc:creator><author>灝忎箤榫?/author><pubDate>Mon, 28 Jul 2008 11:44:00 GMT</pubDate><guid>http://www.shnenglu.com/xiaowugui/archive/2008/07/28/57373.html</guid><wfw:comment>http://www.shnenglu.com/xiaowugui/comments/57373.html</wfw:comment><comments>http://www.shnenglu.com/xiaowugui/archive/2008/07/28/57373.html#Feedback</comments><slash:comments>7</slash:comments><wfw:commentRss>http://www.shnenglu.com/xiaowugui/comments/commentRss/57373.html</wfw:commentRss><trackback:ping>http://www.shnenglu.com/xiaowugui/services/trackbacks/57373.html</trackback:ping><description><![CDATA[浠涔堟槸榪愮畻絎︾殑緇撳悎鎬э紵<br><br>褰撲袱涓繍綆楃鐨勪紭鍏堢駭涓鏍風(fēng)殑鏃跺欙紝鍏堢畻鍝竴涓殑闂錛岃繖灝辨槸緇撳悎鎬с?br><br>棣栧厛瑕佹槑鐧界殑鏄細(xì)緇撳悎鎬у浜庝袱涓垨涓や釜浠ヤ笂鐨勪紭鍏堢駭涓鏍風(fēng)殑榪愮畻絎︽墠鏈夋剰涔夈?br>姣斿錛?br> <div style="BORDER-RIGHT: #cccccc 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #cccccc 1px solid; PADDING-LEFT: 4px; FONT-SIZE: 13px; PADDING-BOTTOM: 4px; BORDER-LEFT: #cccccc 1px solid; WIDTH: 98%; WORD-BREAK: break-all; PADDING-TOP: 4px; BORDER-BOTTOM: #cccccc 1px solid; BACKGROUND-COLOR: #eeeeee"><span style="COLOR: #000000">m </span><span style="COLOR: #000000">=</span><span style="COLOR: #000000"> x </span><span style="COLOR: #000000">+</span><span style="COLOR: #000000"> y </span><span style="COLOR: #000000">-</span><span style="COLOR: #000000"> z;</span></div> <br>鐢變簬綆楁湳榪愮畻絎︾殑緇撳悎鎬ф槸浠庡乏鑷沖彸錛屽洜姝や笂寮忕瓑浠蜂簬錛?br><br> <div style="BORDER-RIGHT: #cccccc 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #cccccc 1px solid; PADDING-LEFT: 4px; FONT-SIZE: 13px; PADDING-BOTTOM: 4px; BORDER-LEFT: #cccccc 1px solid; WIDTH: 98%; WORD-BREAK: break-all; PADDING-TOP: 4px; BORDER-BOTTOM: #cccccc 1px solid; BACKGROUND-COLOR: #eeeeee"><img src="http://www.shnenglu.com/Images/OutliningIndicators/None.gif" align=top><span style="COLOR: #000000">m </span><span style="COLOR: #000000">=</span><span style="COLOR: #000000"> (x </span><span style="COLOR: #000000">+</span><span style="COLOR: #000000"> y) </span><span style="COLOR: #000000">-</span><span style="COLOR: #000000"> z;</span></div> <br>鍐嶆瘮濡傦細(xì)<br> <div style="BORDER-RIGHT: #cccccc 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #cccccc 1px solid; PADDING-LEFT: 4px; FONT-SIZE: 13px; PADDING-BOTTOM: 4px; BORDER-LEFT: #cccccc 1px solid; WIDTH: 98%; WORD-BREAK: break-all; PADDING-TOP: 4px; BORDER-BOTTOM: #cccccc 1px solid; BACKGROUND-COLOR: #eeeeee"><span style="COLOR: #000000">#include </span><span style="COLOR: #000000"><</span><span style="COLOR: #000000">stdio.h</span><span style="COLOR: #000000">></span><span style="COLOR: #000000"><br><br>main()<br>{<br>    </span><span style="COLOR: #0000ff">int</span><span style="COLOR: #000000"> s[</span><span style="COLOR: #000000">2</span><span style="COLOR: #000000">] </span><span style="COLOR: #000000">=</span><span style="COLOR: #000000"> {</span><span style="COLOR: #000000">11</span><span style="COLOR: #000000">, </span><span style="COLOR: #000000">52</span><span style="COLOR: #000000">};<br>    </span><span style="COLOR: #0000ff">int</span><span style="COLOR: #000000"> </span><span style="COLOR: #000000">*</span><span style="COLOR: #000000">ptr </span><span style="COLOR: #000000">=</span><span style="COLOR: #000000"> s;<br><br>    printf(</span><span style="COLOR: #000000">"</span><span style="COLOR: #000000">%d\n</span><span style="COLOR: #000000">"</span><span style="COLOR: #000000">, </span><span style="COLOR: #000000">*++</span><span style="COLOR: #000000">ptr);<br>    </span><span style="COLOR: #0000ff">return</span><span style="COLOR: #000000"> </span><span style="COLOR: #000000">0</span><span style="COLOR: #000000">;<br>}</span></div> 絳旀鏄細(xì)52<br>鐢變簬*鍜?+鐨勭粨鍚堟т粠鍙寵嚦宸︼紝鍥犳*++ptr絳変環(huán)浜?(++ptr)<br><br>鍦ㄧ綉涓婃煡璇㈣祫鏂欑殑鏃跺欏彂鐜幫細(xì)寰堝浜洪棶鏉′歡榪愮畻絎︾殑緇撳悎鎬х殑闂銆?br> <div style="BORDER-RIGHT: #cccccc 1px solid; PADDING-RIGHT: 5px; BORDER-TOP: #cccccc 1px solid; PADDING-LEFT: 4px; FONT-SIZE: 13px; PADDING-BOTTOM: 4px; BORDER-LEFT: #cccccc 1px solid; WIDTH: 98%; WORD-BREAK: break-all; PADDING-TOP: 4px; BORDER-BOTTOM: #cccccc 1px solid; BACKGROUND-COLOR: #eeeeee"><span style="COLOR: #0000ff">int</span><span style="COLOR: #000000"> i </span><span style="COLOR: #000000">=</span><span style="COLOR: #000000"> </span><span style="COLOR: #000000">3</span><span style="COLOR: #000000">;<br></span><span style="COLOR: #0000ff">int</span><span style="COLOR: #000000"> k </span><span style="COLOR: #000000">=</span><span style="COLOR: #000000"> </span><span style="COLOR: #000000">0</span><span style="COLOR: #000000">;<br><br>k </span><span style="COLOR: #000000">=</span><span style="COLOR: #000000"> (i</span><span style="COLOR: #000000">++<</span><span style="COLOR: #000000">0</span><span style="COLOR: #000000">) </span><span style="COLOR: #000000">?</span><span style="COLOR: #000000"> </span><span style="COLOR: #000000">9</span><span style="COLOR: #000000"> : ((i</span><span style="COLOR: #000000">==</span><span style="COLOR: #000000">3</span><span style="COLOR: #000000">) </span><span style="COLOR: #000000">?</span><span style="COLOR: #000000"> </span><span style="COLOR: #000000">10</span><span style="COLOR: #000000"> : </span><span style="COLOR: #000000">8</span><span style="COLOR: #000000">);<br><br>cout </span><span style="COLOR: #000000"><<</span><span style="COLOR: #000000">k;<br></span></div> <br>k = (3<0)?9:((i==3)?10:8);<br>涔嬪悗i鍙樻垚4<br>----銆?br>3<0鏄亣錛屾墍浠涓嶄負(fù)9錛岀戶緇綆椾笅涓姝ャ?br>k = ((i==3)?10:8);<br>----銆?br>鎴戜滑鐭ラ亾榪欐椂鍊檌絳変簬4錛屾墍浠ワ紝((i==3)涓哄亣銆?br>鎵浠涓嶇瓑浜?0錛岃屾槸絳変簬8鍢?br>k = ((i==3)?10:8);<br>----銆?br>k = 8<br><br>鏈変漢闂紝閭f潯浠惰繍綆楃鐨勭粨鍚堟т笖涓嶆槸浠庡乏鑷沖彸浜嗭紝榪欎笌涔︿笂鍐欑殑浠庡彸鑷沖乏涓嶇錛?br>鍏跺疄涓婇潰鏍規(guī)湰鐗墊秹涓嶅埌浠涔堢粨鍚堟х殑闂錛屽彧鏈変竴涓繍綆楃浼?xì)鐗垫秹鍒熬l撳悎鎬у悧銆傝屾潯浠惰繍綆楃鏄疌涓瀹氳綆楅『搴忕殑鍥涗釜榪愮畻絎︿箣涓錛屽洜姝や笂闈㈢殑璁$畻欏哄簭鏄畬鍏ㄦ紜殑銆?br><br> <img src ="http://www.shnenglu.com/xiaowugui/aggbug/57373.html" width = "1" height = "1" /><br><br><div align=right><a style="text-decoration:none;" href="http://www.shnenglu.com/xiaowugui/" target="_blank">灝忎箤榫?/a> 2008-07-28 19:44 <a href="http://www.shnenglu.com/xiaowugui/archive/2008/07/28/57373.html#Feedback" target="_blank" style="text-decoration:none;">鍙戣〃璇勮</a></div>]]></description></item></channel></rss> <footer> <div class="friendship-link"> <p>感谢您访问我们的网站,您可能还对以下资源感兴趣:</p> <a href="http://www.shnenglu.com/" title="精品视频久久久久">精品视频久久久久</a> <div class="friend-links"> </div> </div> </footer> <a href="http://www.pyqf.net.cn" target="_blank">久久精品亚洲男人的天堂</a>| <a href="http://www.yikafei.cn" target="_blank">久久精品国产亚洲AV忘忧草18 </a>| <a href="http://www.jy06.cn" target="_blank">欧美日韩精品久久免费</a>| <a href="http://www.dnsdna.cn" target="_blank">久久久久久精品免费免费自慰</a>| <a href="http://www.skjzy.cn" target="_blank">久久亚洲AV成人无码电影</a>| <a href="http://www.sd2sc.com.cn" target="_blank">久久精品国产99国产精偷</a>| <a href="http://www.tduck.cn" target="_blank">性做久久久久久久久老女人</a>| <a href="http://www.dfux.com.cn" target="_blank">久久精品国产亚洲AV香蕉</a>| <a href="http://www.hfdsbw.cn" target="_blank">久久久久亚洲AV成人网人人网站</a>| <a href="http://www.fa808.cn" target="_blank">国产亚洲精品久久久久秋霞</a>| <a href="http://www.shebianfen.cn" target="_blank">久久99中文字幕久久</a>| <a href="http://www.hhhkk.cn" target="_blank">久久久SS麻豆欧美国产日韩</a>| <a href="http://www.zhaoyang-db.com.cn" target="_blank">国产亚洲婷婷香蕉久久精品</a>| <a href="http://www.tjjxqc.cn" target="_blank">久久久久高潮综合影院</a>| <a href="http://www.guhm.cn" target="_blank">国产女人aaa级久久久级</a>| <a href="http://www.up2me.cn" target="_blank">久久99精品国产自在现线小黄鸭 </a>| <a href="http://www.yunva.cn" target="_blank">久久w5ww成w人免费</a>| <a href="http://www.g8360.cn" target="_blank">午夜精品久久久久久</a>| <a href="http://www.easecorp.com.cn" target="_blank">四虎国产精品免费久久久</a>| <a href="http://www.guceka.cn" target="_blank">亚洲综合日韩久久成人AV</a>| <a href="http://www.mizhewang.cn" target="_blank">久久久久久亚洲精品不卡</a>| <a href="http://www.156v7.cn" target="_blank">色成年激情久久综合</a>| <a href="http://www.bisibbs.cn" target="_blank">国产精品久久毛片完整版</a>| <a href="http://www.zgsmkf.cn" target="_blank">亚洲va久久久噜噜噜久久天堂</a>| <a href="http://www.jswlgs.cn" target="_blank">欧美性大战久久久久久</a>| <a href="http://www.green-products.cn" target="_blank">热99re久久国超精品首页</a>| <a href="http://www.sohucn.com.cn" target="_blank">久久99精品久久久久子伦</a>| <a href="http://www.gyvgllqc.cn" target="_blank">欧洲成人午夜精品无码区久久</a>| <a href="http://www.bbs0310.cn" target="_blank">伊人色综合久久天天网</a>| <a href="http://www.vnzm.cn" target="_blank">伊人久久无码精品中文字幕</a>| <a href="http://www.sdlove.cn" target="_blank">人妻少妇精品久久</a>| <a href="http://www.abensky.cn" target="_blank">久久天天躁狠狠躁夜夜2020</a>| <a href="http://www.366509.cn" target="_blank">国产成人精品久久亚洲高清不卡</a>| <a href="http://www.qlswxflaw.cn" target="_blank">狠狠色丁香婷婷综合久久来 </a>| <a href="http://www.s88w.cn" target="_blank">久久精品国产免费一区</a>| <a href="http://www.lampserver.cn" target="_blank">69久久精品无码一区二区</a>| <a href="http://www.ahsxd.org.cn" target="_blank">色婷婷久久综合中文久久蜜桃av </a>| <a href="http://www.xiaosp4.cn" target="_blank">99久久精品国产毛片</a>| <a href="http://www.dr-knoell-consult.com.cn" target="_blank">91精品国产综合久久精品</a>| <a href="http://www.ghbo.cn" target="_blank">久久久国产精品福利免费</a>| <a href="http://www.287853x.cn" target="_blank">久久精品国产免费一区</a>| <script> (function(){ var bp = document.createElement('script'); var curProtocol = window.location.protocol.split(':')[0]; if (curProtocol === 'https') { bp.src = 'https://zz.bdstatic.com/linksubmit/push.js'; } else { bp.src = 'http://push.zhanzhang.baidu.com/push.js'; } var s = document.getElementsByTagName("script")[0]; s.parentNode.insertBefore(bp, s); })(); </script> </body>