What is difference between initialization and assignment?

Answer Posted / sandeep mannarakkal

All object creation involves two steps,
1) Memory allocation
2) Memory initialization , so initialization is a part of object creation itself.
Assignment is the process of assigning values in to already available object.
Hope the concept is clear

Is This Answer Correct ?    4 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Which software is best for coding?

574


Is c++ used anymore?

592


what you know about c++?

665


How can a called function determine the number of arguments that have been passed to it?

658


How do you show the declaration of a virtual constructor?

532






Which bit wise operator is suitable for turning off a particular bit in a number?

645


Explain dangling pointer.

682


Explain deep copy and a shallow copy?

613


Explain terminate() function?

595


Are php strings immutable?

562


How much is c++ certification?

589


Can a program run without main in c++?

589


When is the destructor called?

607


What is the main function c++?

603


Can we inherit constructor in c++?

591