关于主函数调用指针函数*getstring()
楼主 浮生若茶 来自 物联网-指针函数一 2018-12-10 22:35:10 3人参与讨论
全部回复
-
浮生若茶
#include<stdio.h>
#include<string.h>
char *getstring();
int main(int argc, const char *argv[])
{
printf("....%s....,,%c\n",getstring(),*(getstring()+1));
printf("%p,%s\n",getstring(),getstring());
return 0;
}
char *getstring()
{
static char str[20];
strcpy(str,"hello!");
return str;
}
我的回复
发表成功 M豆+5
每日可获得50M豆,免费兑换开发板
所属分类 全部分类
相关课程
热门问题
FS-MP1A开发板课程视频上线啦,全部开源免费,周周更新,欢迎围观!
14 回答 来自 嵌入式
18 回答 来自 嵌入式
16 回答 来自 嵌入式