Re: passing a string to a C++ function



Leo wrote:
Hmm...thanks for a very unhelpful answer.

let me rephrase it:

char items[3]={"tom","***","harry"}

does that satisfy your "remaining 3 pointers fixation"?


No, because item is an array of char, not an array of const char*.

Note that string literals are of type const char *.
.