Difference Between   char* s   and   char s[]   and   char s[n]

This page answers questions like these:

Related Links:
Difference Between char* s = "string"; and char s[] = "string";
warning: invalid conversion from 'char**' to 'const char**'



Difference Between   char* s   and   char s[]   and   char s[n]

char* s; char s[]; char s[5]; struct MyStruct { char* s; }; struct MyStruct { char s[]; }; int func(char* s) { ... }; int func(char s[]) { ... };



Related Links:
Difference Between char* s = "string"; and char s[] = "string";
warning: invalid conversion from 'char**' to 'const char**'

Home  >  C++ / C  >  Difference Between   char* s   and   char s[]   and   char s[n]


Tags: strings in C, C string, C array length, C char array, char*, char[], bounded array, unbounded array, C++, C

difference-between-char-star-and-char-array.txt
C++-C/difference-between-char-pointer-and-char-array.htm
2