´Óº¯Êý·µ»ØÒ»¸öÊý×éµÄ2ÖÖ·½·¨ (Cר¼Ò±à³Ì p230)
ÑϸñÀ´Ëµ£¬ÎÞ·¨´Óº¯Êý·µ»ØÒ»¸öÊý×飬µ«¿ÉÒÔ´Óº¯Êý·µ»ØÒ»¸öÖ¸ÏòÈκÎÊý¾Ý½á¹¹µÄÖ¸Õ룬°üÀ¨Ò»¸öÖ¸ÏòÊý×éµÄÖ¸Õë¡£
Ò»ÖÖ·½Ê½ÈçÏ£º
#include <stdio.h>
#include <stdlib.h>
int (*func())[20];//funcÊÇÒ»¸öº¯Êý£¬Ëü·µ»ØÒ»¸öÖ¸Ïò°üÀ¨20¸öintÔªËصÄÊý×éµÄÖ¸Õë
int main(void)
{
int (*result)[20];
int i = 0;
result = func();
for(i = 0; i < 20; i++){
printf("%d\n", (*result)[i]);
}
free(result);
exit(0);
}
int (*func())[20]
{
int (*a)[20];
int i = 0;
a = calloc(20, sizeof(int));
if(a == NULL){
perror("calloc error");
exit(1);
}
for(i = 0; i < 20; i++){
a[0][i] = i;
}
return a;
}
ǧÍòҪעÒ⣺²»ÄÜ´Óº¯ÊýÖзµ»ØÒ»¸öÖ¸Ïòº¯ÊýµÄ¾Ö²¿±äÁ¿µÄÖ¸Õë¡£
ÁíÒ»ÖÖ·½Ê½ÈçÏ£º
#include <stdio.h>
#include <stdlib.h>
struct tag{
int array[20];
}x, y;
struct tag func(void);
int main(void)
{
&n
Ïà¹ØÎĵµ£º
VB
If MSComm1.PortOpen = True Then MSComm1.PortOpen = False
MSComm1.CommPort = i1
MSComm1.PortOpen = True
MSComm1.InputMode = comInputModeBinary
MSComm1.InBufferCount = 0
& ......
µ±½ñÓÐÐí¶àÃâ·ÑµÄ RDBMS£¨Relational Database Management
System£¬¹ØϵÊý¾Ý¿â¹ÜÀíϵͳ£©£¬ÆäÖÐһЩÊÇ¿ª·ÅÔ´ÂëÈí¼þ£¬ÁíһЩÊÇÉÌÒµ³§ÉÌÌṩµÄÃâ·Ñ²úÆ·¡£Èç¹ûÄúÕýÔÚʹÓà C/C++¡¢Java™¡¢.NET
»ò PHP
¿ª·¢Ó¦ÓóÌÐò£¬ÏëÑ°ÕÒÒ»ÖÖ¿É¿¿µÄÊý¾Ý·þÎñÆ÷£¬Ï£ÍûËüÖ§³ÖÏȽøµÄ¼¼Êõ¡¢¾ßÓ⻶ÏÀ©´óµÄ¿ª·¢ÈËÔ±ÉçÇø²¢ÒѾ²¿ÊðÔÚÐí¶à¹Ø¼ ......
@ ECHO OFF
@ ECHO.
@ ECHO. Snlie
@ ECHO ---------------------------------------------------------------
@ ECHO NTFS¸ñʽÊÇWinXPÍƼöʹÓõĸñʽ¡£×ª»» ......
֪ʶ½á¹¹:
1¡¢if,for,switch,goto
2¡¢#define,const
3¡¢Îļþ¿½±´µÄ´úÂë,¶¯Ì¬Éú³ÉÄÚ´æ,¸´ºÏ±í´ïʽ,strcpy,memcpy,sizeof
4¡¢º¯Êý²ÎÊý´«µÝ,ÄÚ´æ·ÖÅ䷽ʽ,ÄÚ´æ´íÎó±íÏÖ,mallocÓënewÇø±ð
5¡¢ÀàÖØÔØ¡¢Òþ²ØÓ븲¸ÇÇø±ð,externÎÊÌâ,º¯Êý²ÎÊýµÄȱʡֵÎÊÌâ,ºê´úÂëÓëÄÚÁªº¯ÊýÇø±ð
6¡¢¹¹ÔìºÍÎö¹¹µÄ´ÎÐò,Stringº¯Êý¶¨Òå
¾ß ......
C/C++ÊÇ×îÖ÷ÒªµÄ±à³ÌÓïÑÔ¡£ÕâÀïÁгöÁË50ÃûÓÅÐãÍøÕ¾ºÍÍøÒ³Çåµ¥£¬ÕâЩÍøÕ¾Ìṩc/c++Ô´´úÂë ¡£Õâ·ÝÇåµ¥ÌṩÁËÔ´´úÂëµÄÁ´½ÓÒÔ¼°ËüÃǵÄС˵Ã÷¡£ÎÒÒѾ¡Á¦°üÀ¨×î¼ÑµÄC/C++Ô´´úÂëµÄÍøÕ¾¡£Õâ²»ÊÇÒ»¸öÍêÕûµÄÇåµ¥£¬ÄúÓн¨Òé¿ÉÒÔÁªÏµÎÒ£¬ÎÒ½«»¶ÓÄúµÄ½¨ Ò飬ÒÔ½øÒ»²½¼ÓÇ¿Õâ·½ÃæµÄÇåµ¥¡£
1¡¢http://snippets.dzone.com/tag/c/ --ÊýÒÔǧ ......