Why is it suggested not to use malloc() or calloc() in C++ for memory allocation?
What is the basic principle behind recursion, other than function calling itself again & again and in which real time scenario we use it?
The basic idea behind recursion is that you're solving one big problem by breaking it into multiple smaller, easier-to-solve problems. This can make the algorithm easier to write and un...
Recursion is the process of calling function again and again.During the recursion many push and pop operation is done in our registers memory. That's why recursion has very poor performance.Our compu...
There may be a clash between malloc() and new as they don't HAVE to use the same heap library routines. Also, for arrays of classe objects, new invokes the default constructor. For single class objects new allows you to choose a different constructor.
They cannot call contructors and destructors.