I need to allocate memory dynamically for an array of pointers.
Let us assume,
char *names[50];
char *element;
I used the following code to allocate memory dynamically which is producing error.
names=malloc(sizeof(char *));
Afterwards, i need to assign another character pointer to this one, say
names=element;
I am getting error as ": warning: assignment from incompatible pointer type".
How can i resolve this?