- Addresses vs. pointers
- Understanding the relationship between pointers and arrays
- Dereferencing pointers
- Passing pointers as arguments
- Using new and delete operators
Skill Level Intermediate
- [Peggy] Welcome to Pointers in C++. I'm Peggy Fisher, and I look forward to exploring the use of pointers in C++. We will start by reviewing the definition of a pointer. We'll identify the differences between pointers and addresses. We'll review how memory is allocated for pointers, both at the start of execution of a program and using dynamic allocation once the program is running. We'll provide a demo on how to use pointers, passing pointers to arguments as functions, and more.
C++ has long been recognized as an efficient programming language, and this is in part due to the use of pointers. This type of logic allows us to control memory allocation so we don't allocate more than we need, and we can free memory once it is no longer needed. So let's take a look at pointers in C++.