结构体包含本身指针如何使用
比如
#include <stdio.h> typedef struct info { char p[1024]; struct info* next; }*pInfo,Info; Info* Test()//如何返回首个节点?? { int count = 10; int i = 0; Info *tst; char *ss = "hello"; for (i = 0;i < count;i++) { strcpy(tst->p,ss); //tst->p = ss; tst = tst->next; } return tst;//此处应返回首个节点 } int main() { //printf("%s\n",Test()->p); return 0; }呵呵、不知道问题这样有没有讲清楚。