What is the point of pointers in C++ when I can just declare variables? When is it appropriate to use them?
Sometimes you have a function that needs to return some amount of memory that isn't a set amount, such as reading from a file.
bool ReadDataFromFile(char** contents);
You would declare a char* contents and pass the address of that pointer to the function. That function would then allocate the memory and your pointer would point to the contents upon return.