What will happen if I allocate memory using "new" and free
it using "free" or allocate sing "calloc" and free it using
"delete"?
Answer Posted / sanjay makwana, puna
When you allocate a memory using new then constructor will
be called but when use a free that time destructor will not
be called.
Same vice versa for calloc and delete.
Is This Answer Correct ? | 6 Yes | 0 No |
Post New Answer View All Answers
Write a program to concatenate two strings.
What do you mean by delegate? Can a user retain delegates?
List the types of polymorphism in c++?
Define the process of handling in case of destructor failure?
What are member functions used in c++?
What is a breakpoint?
What is a c++ object?
How is objective c different from c++?
How do I use turbo c++?
What is a syntax in c++?
Explain object slicing in c++?
How does a C++ structure differ from a C++ class?
Can malloc be used in c++?
Which bit wise operator is suitable for turning off a particular bit in a number?
daily Routine of father