BBS514StructuredProgramming(YapsalProgramlama).pptVIP

  • 2
  • 0
  • 约1.26万字
  • 约 31页
  • 2017-04-17 发布于湖北
  • 举报
BBS514StructuredProgramming(YapsalProgramlama)

BBS514 Structured Programming (Yap?sal Programlama) * /* copy t to s; array subscript version */ void strcpy (char *s, char *t) { int i=0; while ((s[i] = t[i]) != ‘\0’) i++; } /copy t to s; pointer version */ void strcpy (char *s, char *t) { while (*s=*t)!=‘\0’){ s++; t++; } } BBS514 Structured Programming (Yap?sal Programlama) * /* Concatenate two strings */ char *strcat(char *s1, char *s2) { char *p; p = s1; while (*p++); --p; while (*p++ = *s2++); return (s1); } BBS514 Structured Programming (Yap?sal Programlama) * #include stdio.h #include string.h #define LENGTH 2

文档评论(0)

1亿VIP精品文档

相关文档