I have an int*
variable that stores memory address, for the example address 0x28c1150
.
I want to know, what value is stored at the address.
edit:
struct list {
int value;
list *next;
list *head = NULL;
void push(int n);
void select();
void pop();
void top();
};
void list::push(int value) {
list *temp = new list;
temp->value = value;
temp->next = head;
head = temp;
}
void list::top(){
list * temp = new list;
cout << head;
}
i want to print top of my list