Question #186173

Develop a C++ program to read the value from user and display the address using wild pointer.


Expert's answer

#include <iostream>
using namespace std;
int main(){
    int *location;
    cout<<"Enter an integer: ";
    int x;
    cin>>x;
    location = &x;
    cout<<"The address where "<<x<<" is stored is "<<location;
    return 0;
}

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

LATEST TUTORIALS
APPROVED BY CLIENTS