this pointer in C++ | Uses of this pointer in C++ | Types of pointers
HTML-код
- Опубликовано: 6 фев 2025
- In this video 2 - part 5 of Chapter 5 of @c2 - Computer Curiosity channel, concept of this pointer in C++ is discussed. It is explained diagrammatically.
Following topics are covered
0:25 this pointer in C++
4:25 Use1 - Use of this pointer in C++ to distinguish between local variable and data member with same name in a member function of class in C++
5:17 Program to show how to distinguish between local variable and data member of class with same name in a class. using this pointer
10:20 Use 2 - Using this pointer to return reference to current object
11:17 Program to show how this pointer is used to return reference to current object
13:07 Use 3 - Use of this pointer to pass current object to member function
13:39 Program to show how to pass current object to member function using this pointer
16:04 Use 4 - Using this pointer to compare objects
16:43 Program to compare objects of a class using this pointer
18:48 Use 5 - Dynamic memory management using this pointer
21:17 Program to show how this pointer is used to perform dynamic memory management
With Live programming examples in support.
lakhanpalpublis...