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

Answer Posted / aruna kumar samal

yes you can use free to free memory assignrd by new but it
wo not call the destructor.

Is This Answer Correct ?    6 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the use of data hiding?

590


Is swift better than c++?

532


How does c++ sort work?

553


Does c++ have arraylist?

532


What is a static member?

604






Is c++ low level?

571


Explain friend class?

622


What are vtable and vptr?

609


How can you prevent accessing of the private parts of my class by other programmers (violating encapsulation)?

637


You have two pairs: new() and delete() and another pair : alloc() and free(). Explain differences between eg. New() and malloc()

586


Tell me what are static member functions?

608


What is object in c++ example?

615


What is purpose of abstract class?

581


What is a singleton c++?

543


Do the parentheses after the type name make a difference with new?

640