I am suppose to store the pointer to a command into a 2d array. Below is a little bit of code that I am using, but I dont know how to get the desired result.
#define MAX_LINE_LENGTH 1024
#define MAX_COMMANDS 10
char *commandHistory[MAX_COMMANDS][MAX_LINE_LENGTH + 1];
char *token;
token = strtok(line, LSH_TOK_DELIM);
printf("%s\n", token); //prints out the command I want to store the pointer to
commandHistory[i++][0] = token; //what do I do here?