Question
Which type of relationship between classes in OOP is
best represented when one class is a part of another class but can exist independently?Solution
Aggregation is a type of association that represents a "whole-part" relationship between two classes. The key characteristic is that the part (child object) can exist independently of the whole (parent object). For instance, in a Team class and Player class, a Player can exist without being associated with a Team . Aggregation is implemented by using references, where one class has an attribute referencing another class. This design principle promotes flexibility and modularity. Aggregation is often represented with a hollow diamond in UML diagrams. Why Other Options Are Wrong Option B : "Inheritance" Inheritance represents an "is-a" relationship, not a "whole-part" relationship. It is used to share functionality between classes, not to model part-whole dependencies. Option C : "Composition" Composition is similar to aggregation but with a crucial difference: the part cannot exist independently of the whole. For example, a Car and its Engine share a composition relationship because an engine has no meaning outside the car. Option D : "Association" Association is a broader concept that describes any relationship between classes. Aggregation is a specific type of association. Option E : "Polymorphism" Polymorphism is unrelated to class relationships and focuses on method behavior.
ANICIPATED рдХреЗ рд▓рд┐рдП рд╕рд╣реА рд╣рд┐рдиреНрджреА рдкрд╛рд░рд┐рднрд╛рд╖рд┐рдХ рд╢рдмреНрдж рд╣реИ-
рдирд┐рдореНрдирд▓рд┐рдЦрд┐рдд рдореЗрдВ рд╕реЗ┬а Tally clerk рдХрд╛ рд╣рд┐рдВрджреА рдореЗрдВ рд╕рд╣реА рдЕрд░реНрде рдХреНрдпрд╛ рд╣реИ ?
Formal job creation surged to 1.5 Lakhs.
рдЕрдВрдЧреНрд░реЗрдЬреА рдХреЗ ‘GRACE’ рдХреЗ рд▓рд┐рдП рд╣рд┐рдиреНрджреА рдХреЗ рдЬрд┐рд╕ рд╢рдмреНрдж рдХрд╛ рдкреНрд░рдпреЛя┐╜...
(A ) рд╡рд┐рд╢реНрд╡ рдореЗрдВ рдХрдИ рджреЗрд╢ рдЕрдкрдиреА рд╕реНрд╡рд╛рд░реНрде рдкреВрд░реНрддрд┐┬а рдХреЗ рд▓рд┐рдП рдХреЛрдИ рднреА рдХрджрдо рдЙя┐╜...
рдирд┐рдореНрдирд▓рд┐рдЦрд┐рдд рд╡рд┐рдХрд▓реНрдкреЛрдВ┬а рдореЗрдВ рд╕реЗ coverage рдХрд╛ рд╣рд┐рдВрджреА рдкрд░реНрдпрд╛рдп рдирд╣реАрдВ рд╣...
рдирд┐рдореНрдирд▓рд┐рдЦрд┐рдд рдореЗрдВ рд╕реЗ Abase рд╢рдмреНрдж рдХрд╛ рдЕрд░реНрде рдирд╣реАрдВ рд╣реИ ?
рдирд┐рдореНрдирд▓рд┐рдЦрд┐рдд рдореЗрдВ рд╕реЗ рд╕рднреА рдХрд┐рд╕реА рди рдХрд┐рд╕реА рдкреНрд░рдХрд╛рд░ рд╕реЗ Current рдХрд╛ рдЕрд░реНрде рдкреНрд░я┐╜...
рдирд┐рдореНрдирд▓рд┐рдЦрд┐рдд рдореЗрдВ рд╕реЗ effective staff strength ┬а рд╢рдмреНрдж рдХрд╛ рд╡рд┐рддреНрддреАрдп рд╢рдмреНрджрд╛рд╡рд▓реА...
Reimbursement рдХреЗ рд▓рд┐рдП рд▓рд┐рдП рд╕рд╣реА рдкрд╛рд░рд┐рднрд╛рд╖рд┐рдХ рд╢рдмреНрдж рд╣реИ