Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- int main()
- {
- using std::cout;
- using std::endl;
- int* ptr = new int(300);
- cout << "Address of the allocated memory: " << ptr << endl;
- cout << "The value in the allocated memory: " << *ptr << endl;
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment