Why does one use pointers instead of adjusting the value that is stored in the variable directly? I've seen plenty of information regarding how to use them, but they never really answered why.
Trivially, sometimes you might want to have one persistent pointer to something, e.g. the start of an array, and another temporary pointer that initially points to the same place, but then moves along the array.
Also, multiple objects may want access to the same other object, so each one would hold a pointer to that other object.
Well one big advantage of storing the address of an existing variable is that you can pass a pointer to the variable for efficiency instead of passing the variable by value. Like for example if you have a vector of string objects (thousands upon thousands of string objects in that vector) and you want to display the elements of that vector, it wouldn't be a very good idea to just plug in the name of the vector in the calling function as an argument and send it by value as it would get copied and that would result in a performance hit.
There are also many good uses for pointers and MikeyBoy covered some of them in that link.
Thank you both for replying and providing information. After seeing both of your responses, I feel I have a better general idea of when and why to use pointers and that is exactly what I was wanting to achieve. I'll leave this post open for a few days to make sure I don't have any more questions before I mark it as Solved. Thanks again!