Question: 1) Read the following code and see whether you can interpret/understand the results. (2) Copy the code to your IDE. Use debugger to see the
1) Read the following code and see whether you can interpret/understand the results. (2) Copy the code to your IDE. Use debugger to see the if the result is the same as your interpreted results.
int a = 5; //assume that a is located at 1000. as pointer is located at 5000
int &b = a;
a = 10;
cout<<&b< int *c = &b; cout< int** cPtrPtr = &c; cout<<*c< cout< int d = 20; int* dPtr = &d; int** dPtrPtr = &dPtr; dPtr= *cPtrPtr; cout<<*dPtr< cout< cout < 8. Introduce a main function that calls all the functions above (No. 7 can be inside a function or inside main).
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
