Question: There cannot be two variables / two functions with the same name in the same scope. Using namespaces, we can create two variable or member
There cannot be two variablestwo functions with the same name in the same scope. Using
namespaces, we can create two variable or member functions having the same name. Justify this
statement with the help of example considering variables and member functions both.
b Explain the use of this pointer with the help of suitable programming example where local
variable of constructor and class data member have the same name.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
