Using c++ smart pointers?
Example:
#include
int main() {
int* p = new int(10);
}
Solution:
#include
int main() {
std::unique_ptr p(new int(10));
}
Example: Solution:Using c++ smart pointers?
#include
#include