案列:指针的指针
发布日期:2021-06-29 11:14:24 浏览次数:2 分类:技术文章

本文共 733 字,大约阅读时间需要 2 分钟。

#include
int main() { char *string; char *a[10]; a[0] = "123123"; a[1] = "234234"; a[2] = "345345"; puts(a[0]); string = a[0]; do { putchar(*string); }while (*string++ != '\0'); printf("\n--------\n"); char **string2; string2 = a; do { do { putchar(*(*string2)); }while (*(*string2)++ != '\0'); printf("\n"); }while (*string2++ != NULL); return 0;}#include
#include
void strycopy_(char * str, char * str_copy);int main() { char * str = "123123www012313"; char str_copy[100]; strycopy_(str, str_copy); puts("str_copy: "); puts(str_copy);}void strycopy_(char * str, char * str_copy) { do { *str_copy = *str; str_copy++; str++; }while (*str != '\0'); *str_copy='\0';}

转载地址:https://blog.csdn.net/ZWHSOUL/article/details/80998523 如侵犯您的版权,请留言回复原文章的地址,我们会给您删除此文章,给您带来不便请您谅解!

上一篇:Java网络编程的socket使用(简单的服务器客户端实现)
下一篇:C语言位操作

发表评论

最新留言

留言是一种美德,欢迎回访!
[***.207.175.100]2024年05月01日 05时17分28秒