O'Reilly logo

Sams Teach Yourself C++ in One Hour a Day, Seventh Edition by Siddhartha Rao

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Lesson 8. Pointers and References Explained

One of the biggest advantages of C++ is that it enables you to write high-level applications that are abstracted from the machine as well as those that work close to the board. Indeed, C++ enables you to tweak the performance of your application on a bytes and bits level.

Understanding how pointers and references work is one step toward being able to write programs that are effective in their consumption of system resources.

In this lesson, you find out

• What pointers are

• What the free store is

• How to use operators new and delete to allocate and free memory

• How to write stable applications using pointers and dynamic allocation

• What references are

• Differences between pointers and references ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required