incrementing an array of pointers in C

后端 未结 5 1987
滥情空心
滥情空心 2020-12-20 20:01

this is probably an essentially trivial thing, but it somewhat escapes me, thus far..

char * a3[2];
a3[0] = \"abc\";
a3[1] = \"def\";
char ** p;

5条回答
  •  感动是毒
    2020-12-20 20:28

    You cannot increment or point any char array to something else after creating. You need to modify or access using index. like a[1]

提交回复
热议问题