C++ Programming - OOPS Concepts - Discussion
Discussion Forum : OOPS Concepts - General Questions (Q.No. 13)
13.
Which of the following concepts provides facility of using object of one class inside another class?
Discussion:
48 comments Page 3 of 5.
Khushbu said:
8 years ago
I think right will be inheritance as it inherits attributes and behavior of a class to another class.
Siva said:
1 decade ago
Still now I can't understand the concept of inheritance? please give me the example for inheritance.
Dev said:
1 decade ago
But in inheritance also we use the object of one class inside another class. Its so confusing.
Karthik said:
1 decade ago
Inheritance is the answer. Its the class inside another existing class.
Answer C is wrong.
Answer C is wrong.
RAHUL said:
1 decade ago
We don't have composition so please can anyone tell what do you mean by composition in c++.
Ronzzz said:
1 decade ago
Still not clear. When class is made up of objects, member functions are not objects then ?
Sachin kunte said:
9 years ago
Composition means containment. Where one object may contain attributes of other object.
Bhuneshwar Mahto said:
6 years ago
I don't know about composition please tell me, anyone, in detail about composition.
(5)
Suman.k said:
1 decade ago
The process of building complex objects from simple ones is called composition.
Hardeep said:
1 decade ago
Can anyone explain me relationship between inheritance and composition?
Post your comments here:
Quick links
Quantitative Aptitude
Verbal (English)
Reasoning
Programming
Interview
Placement Papers