Moving from Java to C++ and new

This question already has an answer here:

  • Why should C++ programmers minimize use of 'new'? 17 answers

  • If you create an object with new, you will be able to access this object from every code of your application, but if you do not delete it, it will be using memory. You can also create objects without new (not using pointers) but those will be deleted when out of scope.

    链接地址: http://www.djcxy.com/p/40648.html

    上一篇: 在C ++中需要关于'new'运算符的帮助

    下一篇: 从Java转向C ++和新的