I'm trying to insert a string to a char* pointer but clearly not working.
I read that I may need to use malloc or something? But the other sites don't share them clearly.
char* token[1000];
gets(token);
printf("%s\n",*token);
Thanks
UPDATE:
Now I have to insert the pointer (which points to the string) to a function with the shown parameter.
int function(char *token[]);
char token[1000];
gets(token);
char*text=token;
printf("%s\n",text);
function(text);
Error of expected ‘char **’ but argument is of type ‘char *’