What is the difference between new/delete and malloc/free?
Answer Posted / neelam saini
Malloc/free do not know about constructors and destructors. New and delete create and destroy objects, while malloc and free allocate and deallocate memory.
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Why is c++ considered difficult?
What language does google use?
Will a catch statement catch a derived exception if it is looking for the base class?
Is there finally in c++?
How do you differentiate between overloading the prefix and postfix increments?
What is istream c++?
Why do we need constructors in c++?
Explain binary search.
Is java easier than c++?
What is data hiding c++?
Define 'std'.
What is auto used for in c++?
How much maximum can you allocate in a single call to malloc()?
What new()is different from malloc()?
Can a class be static in c++?