Course Content
C++ Pointers and References
3. References Fundamentals
C++ Pointers and References
Pointer Arithmetic Practice
Task
- Create a pointer that points to the first variable.
- Find the distance between memory locations of this two variables.
- Using the pointer arithmetic move the pointer to the location of the second variable.
- Modify the value of dereferenced pointer and output the second variable.
Everything was clear?
Section 2. Chapter 2
Course Content
C++ Pointers and References
3. References Fundamentals
C++ Pointers and References
Pointer Arithmetic Practice
Task
- Create a pointer that points to the first variable.
- Find the distance between memory locations of this two variables.
- Using the pointer arithmetic move the pointer to the location of the second variable.
- Modify the value of dereferenced pointer and output the second variable.
Everything was clear?
Section 2. Chapter 2