What is the difference between a shallow copy and a deep copy?
Answer Posted / nashiinformaticssolutions
• Shallow Copy: Copies memory addresses. Changes in one object affect the other.
• Deep Copy: Creates a new copy of the actual data, independent of the original.
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Write a program that takes a 5 digit number and calculates 2 power that number and prints it.
Can I have a reference as a data member of a class? If yes, then how do I initialise it?
What is the difference between function overloading and operator overloading?
How do I run a program in notepad ++?
Difference between delete and free.
Why do we use using namespace std in c++?
Explain one method to process an entire string as one unit?
Refer to a name of class or function that is defined within a namespace?
Explain the static storage classes in c++.
What do you mean by late binding?
What are guid? Why does com need guids?
How does work in c++?
What is the c++ programming language used for?
Is c++ a float?
What would happen on forgetting [], while deallocating an array through new?