I have arrays of strings. I want to put these arrays into an array. How can I do so? I have tried this:
char const * const fruits[3] = {
"apple",
"banana",
"orange",
};
char const * const colors[3] = {
"red",
"green",
"blue",
};
char * preset_configurations[3] =
{
NULL, /* leave the first one blank so that this list is 1-based */
&fruits,
&colors,
};
but I get warning: initialization from incompatible pointer type
. Any idea?