Thursday, July 9, 2009

Does new operator in C++ initialize memory to zero?

No. If you need your memory to be zeroed, either fill it yourself after using new(), or use calloc() instead.


No comments:

Post a Comment