Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

ÈçºÎд³öÓÅÃÀµÄ C ´úÂë


¼¶±ð£º ³õ¼¶
Çñ ¿¡ÌÎ
(juntao.qiu@gmail.com
), Èí¼þ¹¤³Ìʦ, Jinfonet
2009 Äê 9 ÔÂ 25 ÈÕ
ÃæÏò¶ÔÏóµÄÓïÑÔ¸ü½Ó½üÈ˵Ä˼ά·½Ê½£¬¶øÇÒÔںܴó³Ì¶ÈÉϽµµÍÁË´úÂëµÄ¸´ÔÓÐÔ£¬Í¬Ê±Ìá¸ßÁË´úÂëµÄ¿É¶ÁÐԺͿÉά»¤ÐÔ£¬´«Í³µÄ C ´úÂëͬÑù¿ÉÒÔÉè¼Æ³ö±È½ÏÒ׶Á£¬Ò×ά»¤£¬¸´ÔӶȽϵ͵ÄÓÅÃÀ´úÂ룬±¾ÎĽ«Í¨¹ýÒ»¸öʵ¼ÊµÄÀý×ÓÀ´ËµÃ÷ÕâÒ»µã¡£
»ù´¡ÖªÊ¶
½á¹¹Ìå
³ýÁËÌṩ»ù±¾Êý¾ÝÀàÐÍÍ⣬C ÓïÑÔ»¹Ìṩ¸øÓû§×Ô¼º¶¨ÖÆÊý¾ÝÀàÐ͵ÄÄÜÁ¦£¬ÄǾÍÊǽṹÌ壬ÔÚ C ÓïÑÔÖУ¬Äã¿ÉÒÔÓýṹÌåÀ´±íʾÈκÎʵÌå¡£½á¹¹ÌåÕýÊÇÃæÏò¶ÔÏóÓïÑÔÖеÄÀàµÄ¸ÅÄîµÄ³ûÐΣ¬±ÈÈ磺
typedef struct{
float x;
float y;
}Point;
¶¨ÒåÁËÒ»¸öƽÃæ×ø±êϵÖеÄÒ»¸öµã£¬µãÖÐÓÐÁ½¸öÓò£¬x ×ø±êºÍ y ×ø±ê¡£
½á¹¹ÌåÖеÄÓò³ÆΪ½á¹¹ÌåµÄ³ÉÔ±
¡£½á¹¹ÌåÖеÄÊý¾ÝÀàÐÍ¿ÉÒÔÊǼòµ¥Êý¾ÝÀàÐÍ£¬Ò²¿ÉÒÔÊÇÆäËûµÄ½á¹¹Ì壬ÉõÖÁ½á¹¹Ìå±¾Éí»¹¿ÉÒÔǶÌ×£¬±ÈÈ磬һ¸ö±ê×¼µÄÁ´±í½á¹¹¿ÉÒÔ½øÐÐÈç϶¨Ò壺
typedef struct node{
void *data;// Êý¾ÝÖ¸Õë
int dataLength;// Êý¾Ý³¤¶È
struct node *next;// Ö¸ÏòÏÂÒ»¸ö½Úµã
}Node;
¿ÉÒÔ¿´µ½£¬½á¹¹Ìå node ÖÐµÄ next Ö¸ÕëµÄÀàÐÍÓÖÊÇ node ÀàÐÍ¡£
º¯ÊýÖ¸Õë
Ö¸ÕëÊÇ C ÓïÑÔµÄÁé»ê£¬ÊÇ C ±ÈÆäËûÓïÑÔ¸üÁé»î£¬¸üÇ¿´óµÄµØ·½¡£ËùÒÔѧϰ C ÓïÑÔ±ØÐëºÜºÃµÄÕÆÎÕÖ¸Õë¡£º¯ÊýÖ¸Õ룬¼´Ö¸Ïòº¯ÊýÔÚÄÚ´æÓ³ÉäÖеÄÊ×µØÖ·µÄÖ¸Õ룬ͨ¹ýº¯ÊýÖ¸Õ룬¿ÉÒÔ½«º¯Êý×÷Ϊ²ÎÊý´«µÝ¸øÁíÒ»¸öº¯Êý£¬²¢ÔÚÊʵ±µÄʱºòµ÷Ó㬴ӶøʵÏÖÒ첽ͨÐŵȹ¦ÄÜ¡£
±ÈÈ磬 UNIX/Linux ϵͳÖеÄÐźÅ×¢²áº¯Êý£¬ÆäÔ­ÐÍÈçÏ£º
void (*signal(int signo,void (*func)(int))) (int)
ʹÓõÄʱºò£¬ÐèÒª×Ô¼ºÔÚÍⲿ¶¨ÒåÒ»¸öÐźŴ¦Àíº¯Êý (signal handler), È»ºóʹÓà signal(sigNo, handler) ½«´¦Àí³ÌÐò×¢²áÔÚ½ø³ÌÉÏ£¬µ±Ðźŷ¢Éúʱ£¬½ø³Ì¾Í¿ÉÒԻص÷ÐźŴ¦Àíº¯Êý¡£
½«º¯ÊýÖ¸Õë×÷Ϊ½á¹¹ÌåµÄ³ÉÔ±
ÕýÈçÇ°ÃæÌáµ½µÄ£¬½á¹¹ÌåµÄ³ÉÔ±¿ÉÒÔÊǼòµ¥µÄÊý¾Ý½á¹¹£¬Ò²¿ÉÒÔÊÇÆäËûµÄ½á¹¹Ì壬µ±È»£¬Ò²¿ÉÒÔÊÇÖ¸Õë¡£µ±½«º¯ÊýÖ¸Õë×÷Ϊ½á¹¹ÌåµÄ³ÉÔ±£¬²¢ÇÒÕâЩº¯ÊýÖ»ÓÃÀ´²Ù×÷±¾
½á¹¹ÌåÖеÄÊý¾Ýʱ£¬¾Í¿ÉÒÔÐγÉÒ»¸ö¶ÀÁ¢µÄʵÌ壬Õâ¸öʵÌåÖмÈÓÐÊý¾Ý£¬Ò²ÓжÔÊý¾ÝµÄ²Ù×÷£¬ÕâÑù×ÔÈ»¾Í¿ÉÒÔÒý³öÀà
(class)
µÄ¸ÅÄî¡£
»ØÒ³Ê×
ÃæÏò¶ÔÏóÓïÑÔµÄÌØÐÔ
Ò»
°ã¶øÑÔ£¬¼Ì³Ð£¬·â×°ºÍ¶à̬±»ÈÏΪÊÇÃæÏò¶ÔÏóÓïÑÔËù±ØÐëÖ§³ÖµÄÈýÖÖÌØÕ÷£¬Ò²ÕýÊÇͨ¹ýÕâÈýÖÖÌØÕ÷²Å¿ÉÒÔÌåÏÖ³öÃæÏò¶ÔÏóÔÚÄÄЩ·½ÃæÓÅÓÚÃæÏò¹ý³Ì¡£ÓÉÓÚÓïÑÔ¿ª·¢ÉÌ
µÄÐû´«»òÆäËûµÄ¸÷ÖÖÔ­Òò£¬Ê¹µ


Ïà¹ØÎĵµ£º

C preprocessor

http://en.wikipedia.org/wiki/C_preprocessor
C preprocessor
from Wikipedia, the free encyclopedia
Jump to:navigation, search
The C preprocessor (cpp) is the preprocessor for the C programming language. In many C implementations, it is a separate program invoked by the compiler as the first part ......

¡¾Á´½Ó¡¿C/C++ Online Reference


C/C++ Reference 
http://www.cppreference.com/ 
C++ Library Reference 
http://www.cplusplus.com/ref/ 
Standard C++ Library Class Reference at Rogue Wave 
http://www.roguewave.com/support/docs/hppdocs/stdref/ 
Dink ......

C++ÓëCµÄÇø±ð ±±º£

1£©  º¯ÊýÉùÃ÷
l         CÈç¹û²»Ð´·µ»ØÖµ£¬Ä¬ÈÏÊÇint£¬¶øC++Öв»Äܲ»Ð´·µ»ØÖµ(¿ÉÓÃvoid±íʾÎÞ·µ»ØÖµ)¡£
ÈçFunc1();
l         int Func1()ÔÚCÖбíʾ¿É´øÈÎÒâ²ÎÊýµÄº¯Êý£¬ÕâÊÇCµÄ©¶´£¬Ê¹µÃËü±Ü¿ªÁ˲ÎÊýÀàÐͼì²é£»¶øC++Öбíʾ²»´ ......

linux³£ÓÃcÍ·Îļþ

linux³£ÓÃÍ·ÎļþÈçÏ£º
POSIX±ê×¼¶¨ÒåµÄÍ·Îļþ
<dirent.h>       
Ŀ¼Ïî
<fcntl.h>         Îļþ¿ØÖÆ
<fnmatch.h>    ÎļþÃûÆ¥ÅäÀàÐÍ
<glob.h>   
·¾¶ÃûģʽƥÅäÀàÐÍ
< ......

̽Ë÷еÄC + +ºÍMFCÔÚVisual Studio 2010¹¦ÄÜ

̽Ë÷еÄC + +ºÍMFCÔÚVisual Studio 2010¹¦ÄÜ
Sumit Kumar
2010ÄêÁгöµÄVisual Studio C + +¿ª·¢µÄ¾Þ´óºÃ´¦¡£´Ó¹ÍÓÃÄÜÁ¦ÌṩÓÉWindows 7´óÁ¿´úÂëµÄ»ù´¡¹¤×÷£¬ÒÔÔöÇ¿Éú²úÁ¦ÌØÕ÷µÄÐÂÌص㣬ÓÐһЩеĶ«Î÷£¬Ìá¸ßÁ˼¸ºõËùÓеÄC + +¿ª·¢ÈËÔ±¡£
ÔÚÕâƪÎÄÕÂÖУ¬ÎÒ½«½âÊÍ΢ÈíÒѾ­½â¾öÁËÈçºÎÓÃC + +¿ª·¢ÈËÔ±ËùÃæÁٵĹ㷺µÄһЩÎÊÌ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ