Shall we use 'free' to free memory assigned by new, What are
the further consequences??

Answer Posted / uma sankar pradhan

No,we shouldnot use 'free' to free memory assigned by new.
It causes memory leak and sometimes hanging of the system

Is This Answer Correct ?    3 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

When you overload member functions, in what ways must they differ?

592


When does a name clash occur in c++?

717


Comment on c++ standard exceptions?

640


what are the characteristics of Class Members in C++?

596


What does 7/9*9 equal ? a) 1 b) 0.08642 c) 0

585






How would you use the functions memcpy(), memset(), memmove()?

625


What does #define mean in c++?

617


How would you call C functions from C++ and vice versa?

640


Difference between an inspector and a mutator

777


What are the five basic elements of a c++ program?

585


What kind of problems can be solved by a namespace?

594


In a function declaration, what does extern mean?

640


Can you sort a set c++?

532


What is the difference between #import and #include in c++?

599


what is the difference between linear list linked representaion and linked representation? what is the purpose of representing the linear list in linked represention ? is it not avoiding rules of linear represention?

1748