So, my professor has asked us to declare a pointer capable of pointing at an int. Then continue to make the pointer point at a new integer. Then continue to print out the address of that new integer and the address of that pointer. So I`ve never written pointer but I have attempted. So my question is this right?
1 2 3 4 5 6 7 8 9
#include <iostream>
usingnamespace std;
int main(){
int*newint; // declaring a pointer that will point at an int and point at a new
// integer
cout<<&newint<<endl; //finding the new integer address?
}