the difference between new and malloc

Answer Posted / swati

In case of Malloc we need to specify the size of memory for
our data types. But in case of New we do not need to specify
the size.

Is This Answer Correct ?    4 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Can a destructor be called directly?

809


What is Difference Between Inheritance and creating object and getting data? means Class A extends B{ B.getMethod();} (OR) Class A{ b obj=new B(); obj.getMethod(); }

2210


What are main features of oop?

877


Can static class have constructor?

787


Can we create object of abstract class?

827


What is oops and its features?

831


What is oops with example?

769


What is class and example?

819


How do you define a class in oop?

857


State what is encapsulation and friend function?

945


What is the real life example of polymorphism?

854


What is the purpose of polymorphism?

881


What does and I oop mean in text?

859


Write a c++ program to display pass and fail for three student using static member function

3091


What is object and example?

881