So for my assignment, I'm supposed to fill ten strings from a file using an array of pointers. Now I know I'm doing this wrong since my compiler is telling me that there are errors on the levels of indirection. Pointers are so confusing... >_>
char* pStrings; char** pWalker; FILE* spIn; spIn = fopen("numbers.txt", "r"); while(fgets(pStrings, sizeof(pStrings), spIn)) printf("%s", pStrings); printf("\n");
Well it technically still works, but given the errors from my compiler I think I'm doing something wrong. Do I need another array for the pStrings to be referenced to?