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

C ³ÌÐòÎÊÌ⣨ËÄ£© - C/C++ / CÓïÑÔ

#include "stdio.h"

int main()
{
  char *ch(char *, char *);
  char str1[]="I am glad to meet you!";
  char str2[]="Welcom to study C!";
  printf("%s", ch(str1, str2));

return 0;
}

char *ch(char *str1, char *str2)
{
  char *p;
  p=str2;
  if(*str2 == NULL)
return NULL;
// exit(-1);

  do
  {
  *str2=*str1;
  str1++;
  str2++;
  }while(*str1!=NULL);

  return(p);
}
ÎÊÌâÒ»£ºÎªÊ²Ã´Êä³öÊÇ£ºI am glad to meet you!am glad to meet you!
  ¼´£ºÎªÊ²Ã´str2[]»á±»¸Ä³ÉI am glad to meet you!am glad to meet you!ÄØ£¿
  ÎÒµ¥²½µ÷ÊÔʱ¾õµÃstr2[] = I am glad to meet you!ô£¿

ÎÊÌâ¶þ£ºÔÚchar* ch(char *str1, char *str2)º¯ÊýÖУ¬pÊǾֲ¿Ö¸Õ룬×îºóÓÃreturn(p);À´·µ»ØÖ¸ÕëµØÖ·ÊÇ·ñ
  ²»Ì«°²È«ÄØ£¿Èç¹ûÊǵĻ°£¬ÎÒ¿ÉÒÔÔõô¸Ä»òÕßÔõô×ö±È½ÏºÃ£¿

лл£¡£¡£¡

ûÊ£¬pµÄµØַʵ¼ÊÉÏÊÇstr2£¬¸Ä¶¯str2¾ÍÊǸÄp£¬ËùÒÔÄÜ·µ»Ø£¬¶øÇÒp»á¸ú×Åstr2µÄ¸Ä¶¯×ß

*str2 = '\0';
ÉÙÁËÕâ¸ö,

¹ÛÍûÖÐ
û¶àÉÙ·ÖÁË

ÒýÓÃ
#include <stdio.h>

int main()
{
    char *ch(char *, char *);
    char str1[]="I am glad to meet you!";
 


Ïà¹ØÎÊ´ð£º

ѧϰÌÖÂÛ C/C++ QQȺ - C/C++ / ·Ç¼¼ÊõÇø

QQȺ 29152388
ÓÑÇéUP

°ï¶¥

up

°ïup

up Ö§³Ö£¡

up jf

...ÄѵÀÓзÖ..?

up up up
Ï£ÍûÓеüӷ֣¬¹þ¹þ¡£

Ö§³Ö£¬ÎÒ¼ÓÁË£¬Ï£ÍûÂ¥Ö÷ÄܼÓÎÒ£¬¹²Í¬Ñ§Ï°¹þ

¼ÓÁË¡£

¶¥ÉÏ£¬Ã¿ÌìÊÕ»ñÒ»µã£¬Ö§³Ö ......

ÈçºÎ²éÕÒϵͳδ°²×°²¹¶¡C - C/C++ / ÐÂÊÖÀÖÔ°

ÇëÎʸ÷λ¸ßÊÖÈçºÎÓÃC/C++»ñµÃϵͳδ°²×°²¹¶¡
ºÃÏñºÜרҵµÄ¶«Î÷¡£¡£¡£

²é×¢²á±í
ÿ¸ö²¹¶¡Èç¹û°²×°Á˶¼»áÔÚ×¢²á±íÀïÃæµÇ¼Ç

ÇëÎÊÄܲ»ÄܸüÇåÎúЩ£¬ÎÒÏëÓÃc\c++²é³öÀ´£¬²»ºÃÒâ˼£¬ÎÒÊÇÐÂÊÖ¡£»¹ÍûÖ¸½Ì¡£Ð»

·ÖÖµ ......

c,c++Á¬½Ómysql ÕÒ²»µ½Í·²¿Îļþ£¨ÐÂÊÖ£©

±àÒëÆ÷£ºC-Free4
mysql µ¥¶À°²×°µÄ£¬ÏÖÔÚΪapache+php+mysql¿ÉÒÔʹÓá£
×î½üÔÚÁ·Ï°c£¬c++£»ÏëÓÃc£¬c++Á¬½ÓÏÂÎÒµÄmysql£¬ºÃ¶àµØ·½¶à˵mysql.hÕÒ²»µ½¡£¶øÇÒÎÒmysqlûÓÐËùνµÄincludeÎļþ¼Ð°¡¡£
Íü¸ßÊÖÖ¸µãÒ»¶ ......

linux»·¾³ÏÂgethostbynameº¯ÊýÎÊÌâ - C/C++ / CÓïÑÔ

дÁ˸ö²âÊÔ³ÌÐòÈçÏÂ
   
  struct hostent *hp; 
char AlarmDevIP[20];  
  int x2;

hp = gethostbyname("www.google.com");
if (hp)
{ ......

ÎÊÁ½µÀ C ÃæÊÔÌ⣬¸ßÊÖ°ï¿´Ò»ÏÂ

1. Èç϶¨Òå»áÓÐʲô´íÎó·¢Éú
  //file1.c
  int a[10];
  //file2.c
  extern int *a;
2. ´óÈÝÁ¿È«¾Ö±äÁ¿ÓÐʲôΣº¦£¬Èç
   
  //file.c
  ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ