In c++ ,if we want to destroy the built-in type(as to int) to save the memory when the program is running how we should do?if We do like this:
int h;
int *p=&h;
delete p;
To destroy h,I need to create a pointer which points to h then execute the delete operation,but pointer p still consumes the equal memory,it seems like that I didn't do anything to save the running memory,what should I do?