Rabu, 28 September 2016

what is object composition and friend function in C++

Object Composition   In real-world programs an object is made up of several parts. For example a car is made up of several parts (objects) like engine, wheel, door etc. This kind of whole part relationship is known as composition which is also known as has-a relationship. Composition allows us to create separate class for each task. Following are the advantages or benefits of composition: Each class can be simple and straightforward. A class can focus on performing one specific task. Classes will be easier to write, debug, understand, and usable by other people. Lowers the overall complexity of the

The post what is object composition and friend function in C++ appeared first on Coding Security.


what is object composition and friend function in C++
read more

Tidak ada komentar:

Posting Komentar