/** Example showing lifetime of dynamically allocated storage and a * a small memory leak. */ #include using namespace std; void ninetynine(); int main() { ninetynine(); // ... do some other stuff ... // return 0; } void ninetynine() { int *localPtr = new int; *localPtr = 99; cout << *localPtr << endl; }