OOP · Advanced & Patterns interview questions

48 real OOP · Advanced & Patterns questions from the Computer Science Fundamentals bank, as asked in Indian campus drives and tech interviews. Every question has a verified answer and an AI-tutor explanation on placd — free to start.

1. What is association?

Junior
  1. A.a behavioral pattern where subjects notify a list of dependent observers automatically on state change
  2. B.an architecture splitting an application into Model data, View presentation, and Controller logic
  3. C.the SOLID rule that software should be open for extension but closed for modification
  4. D.a general relationship where one object uses or knows about another, with independent lifetimes
Reveal the answer + AI explanation — free account

3. Which statement is correct?

Junior
  1. A.association — the degree of interdependence between modules, which good design keeps low
  2. B.association — a creational pattern that delegates object creation to a method so callers need not name concrete classes
  3. C.association — a general relationship where one object uses or knows about another, with independent lifetimes
  4. D.association — the SOLID rule that a subtype must be usable anywhere its base type is expected without breaking behavior
Reveal the answer + AI explanation — free account

4. What is aggregation?

Junior
  1. A.a general relationship where one object uses or knows about another, with independent lifetimes
  2. B.an architecture splitting an application into Model data, View presentation, and Controller logic
  3. C.a shallow copy duplicates references to shared sub-objects, while a deep copy clones the entire object graph
  4. D.a has-a relationship where the part can exist independently of the whole that contains it
Reveal the answer + AI explanation — free account

6. Which statement is correct?

Junior
  1. A.aggregation — the SOLID rule that software should be open for extension but closed for modification
  2. B.aggregation — a has-a relationship where the part can exist independently of the whole that contains it
  3. C.aggregation — supplying an object's required collaborators from outside rather than having it construct them itself
  4. D.aggregation — a strong has-a relationship where the part's lifetime is owned by and tied to the whole
Reveal the answer + AI explanation — free account

7. What is composition?

Junior
  1. A.the degree to which a module's elements belong together, which good design keeps high
  2. B.the SOLID rule that software should be open for extension but closed for modification
  3. C.a creational pattern that delegates object creation to a method so callers need not name concrete classes
  4. D.a strong has-a relationship where the part's lifetime is owned by and tied to the whole
Reveal the answer + AI explanation — free account

9. Which statement is correct?

Junior
  1. A.composition — the degree to which a module's elements belong together, which good design keeps high
  2. B.composition — a strong has-a relationship where the part's lifetime is owned by and tied to the whole
  3. C.composition — the SOLID rule that modules should depend on abstractions, not on concrete implementations
  4. D.composition — the SOLID rule that software should be open for extension but closed for modification
Reveal the answer + AI explanation — free account

10. What is coupling?

Mid
  1. A.a strong has-a relationship where the part's lifetime is owned by and tied to the whole
  2. B.the SOLID rule that software should be open for extension but closed for modification
  3. C.the degree of interdependence between modules, which good design keeps low
  4. D.a has-a relationship where the part can exist independently of the whole that contains it
Reveal the answer + AI explanation — free account

12. Which statement is correct?

Mid
  1. A.coupling — the degree of interdependence between modules, which good design keeps low
  2. B.coupling — a shallow copy duplicates references to shared sub-objects, while a deep copy clones the entire object graph
  3. C.coupling — a has-a relationship where the part can exist independently of the whole that contains it
  4. D.coupling — a creational pattern that delegates object creation to a method so callers need not name concrete classes
Reveal the answer + AI explanation — free account

13. What is cohesion?

Mid
  1. A.the degree to which a module's elements belong together, which good design keeps high
  2. B.supplying an object's required collaborators from outside rather than having it construct them itself
  3. C.a general relationship where one object uses or knows about another, with independent lifetimes
  4. D.the SOLID rule that clients should not be forced to depend on methods they do not use
Reveal the answer + AI explanation — free account

15. Which statement is correct?

Mid
  1. A.cohesion — the SOLID rule that clients should not be forced to depend on methods they do not use
  2. B.cohesion — an architecture splitting an application into Model data, View presentation, and Controller logic
  3. C.cohesion — a shallow copy duplicates references to shared sub-objects, while a deep copy clones the entire object graph
  4. D.cohesion — the degree to which a module's elements belong together, which good design keeps high
Reveal the answer + AI explanation — free account

16. What is single responsibility principle?

Mid
  1. A.an architecture splitting an application into Model data, View presentation, and Controller logic
  2. B.the SOLID rule that a class should have only one reason to change
  3. C.a general relationship where one object uses or knows about another, with independent lifetimes
  4. D.a has-a relationship where the part can exist independently of the whole that contains it
Reveal the answer + AI explanation — free account

18. Which statement is correct?

Mid
  1. A.single responsibility principle — a design pattern ensuring a class has exactly one instance with a global access point
  2. B.single responsibility principle — the degree of interdependence between modules, which good design keeps low
  3. C.single responsibility principle — supplying an object's required collaborators from outside rather than having it construct them itself
  4. D.single responsibility principle — the SOLID rule that a class should have only one reason to change
Reveal the answer + AI explanation — free account

19. What is open-closed principle?

Mid
  1. A.a has-a relationship where the part can exist independently of the whole that contains it
  2. B.a behavioral pattern where subjects notify a list of dependent observers automatically on state change
  3. C.the SOLID rule that software should be open for extension but closed for modification
  4. D.the degree of interdependence between modules, which good design keeps low
Reveal the answer + AI explanation — free account

21. Which statement is correct?

Mid
  1. A.open-closed principle — an architecture splitting an application into Model data, View presentation, and Controller logic
  2. B.open-closed principle — the SOLID rule that software should be open for extension but closed for modification
  3. C.open-closed principle — a creational pattern that delegates object creation to a method so callers need not name concrete classes
  4. D.open-closed principle — a strong has-a relationship where the part's lifetime is owned by and tied to the whole
Reveal the answer + AI explanation — free account

22. What is Liskov substitution principle?

Mid
  1. A.a shallow copy duplicates references to shared sub-objects, while a deep copy clones the entire object graph
  2. B.the SOLID rule that a subtype must be usable anywhere its base type is expected without breaking behavior
  3. C.a behavioral pattern where subjects notify a list of dependent observers automatically on state change
  4. D.a design pattern ensuring a class has exactly one instance with a global access point
Reveal the answer + AI explanation — free account

24. Which statement is correct?

Mid
  1. A.Liskov substitution principle — a has-a relationship where the part can exist independently of the whole that contains it
  2. B.Liskov substitution principle — the SOLID rule that a subtype must be usable anywhere its base type is expected without breaking behavior
  3. C.Liskov substitution principle — a general relationship where one object uses or knows about another, with independent lifetimes
  4. D.Liskov substitution principle — the SOLID rule that modules should depend on abstractions, not on concrete implementations
Reveal the answer + AI explanation — free account

25. What is dependency inversion principle?

Mid
  1. A.supplying an object's required collaborators from outside rather than having it construct them itself
  2. B.the SOLID rule that software should be open for extension but closed for modification
  3. C.a general relationship where one object uses or knows about another, with independent lifetimes
  4. D.the SOLID rule that modules should depend on abstractions, not on concrete implementations
Reveal the answer + AI explanation — free account

26. Which term means: "the SOLID rule that modules should depend on abstractions, not on concrete implementations"?

Mid
  1. A.open-closed principle
  2. B.Liskov substitution principle
  3. C.dependency inversion principle
  4. D.shallow vs deep copy
Reveal the answer + AI explanation — free account

27. Which statement is correct?

Mid
  1. A.dependency inversion principle — the SOLID rule that clients should not be forced to depend on methods they do not use
  2. B.dependency inversion principle — a design pattern ensuring a class has exactly one instance with a global access point
  3. C.dependency inversion principle — the SOLID rule that modules should depend on abstractions, not on concrete implementations
  4. D.dependency inversion principle — an architecture splitting an application into Model data, View presentation, and Controller logic
Reveal the answer + AI explanation — free account

28. What is singleton pattern?

Mid
  1. A.the SOLID rule that clients should not be forced to depend on methods they do not use
  2. B.an architecture splitting an application into Model data, View presentation, and Controller logic
  3. C.a design pattern ensuring a class has exactly one instance with a global access point
  4. D.the SOLID rule that modules should depend on abstractions, not on concrete implementations
Reveal the answer + AI explanation — free account

29. Which term means: "a design pattern ensuring a class has exactly one instance with a global access point"?

Mid
  1. A.singleton pattern
  2. B.single responsibility principle
  3. C.MVC pattern
  4. D.interface segregation principle
Reveal the answer + AI explanation — free account

30. Which statement is correct?

Mid
  1. A.singleton pattern — an architecture splitting an application into Model data, View presentation, and Controller logic
  2. B.singleton pattern — a behavioral pattern where subjects notify a list of dependent observers automatically on state change
  3. C.singleton pattern — a design pattern ensuring a class has exactly one instance with a global access point
  4. D.singleton pattern — supplying an object's required collaborators from outside rather than having it construct them itself
Reveal the answer + AI explanation — free account

Showing 30 of 48 OOP · Advanced & Patterns questions — the full set, with answers, explanations and an AI tutor on every question, is inside.

Free to start

Answers, AI explanations, and a scored voice mock interview

Sign up free to check your answers with explanations, ask the AI tutor anything on any question, and take one full AI mock interview — scored like a real panel.

Practice OOP · Advanced & Patterns free