I have managed to get to grips with pointers and think I understand waht is going on here.
The only thing I can't get my head round is why I would use a pointer to get the value of a variable from it's storage location when I could just use the variable name. ie what is the advantage of referring to the value with a pointer rather than the variable name, surely the end result is the same in either case in that the value is the same.
Have you read about functions? And about pass-by-value & pass-by-reference? if not, read it and you will get to know about atleast one reason that why we need pointers. :)
There are many other reasons that other members of the community may list down for you or you may come across as you progress in your C++ course.
Here's a good article: http://stackoverflow.com/questions/162941/why-use-pointers
I have an account with Stack Overflow and I trust the information harvested from there.
The only thing I can't get my head round is why I would use a pointer to get...
This may seem like a flippant answer but here goes; Don't use pointers unless you have to, when you have to use pointers you will then now why you use them. As long as you know how to use them the why will come later.
ive always thought because its quicker and cheaper to pass a pointer to the data then moving and passing around the actual data itself. but i could very well be wrong im just a beginner.
The amount of data could be huge, so it just seems natural to use a pointer to it instead.