0

Why we use compositions in c++?

Here we uses classes constructors methods. we can use this directly without saying or showing it like a composition.

17th Oct 2018, 10:05 PM
NIKHIL SHEKHAR
NIKHIL SHEKHAR - avatar
1 Answer
+ 1
ObjectĀ CompositionĀ is useful in a C++ context becauseĀ itĀ allows us to create complex classes by combining simpler, more easily manageable parts. This reduces complexity, and allows us to write code faster and with less errors becauseĀ weĀ can reuse code that has already been written, tested, and verified as working.
9th May 2019, 6:23 AM
kiran m h
kiran m h - avatar