Home
Explore
Exams
Search for anything
Login
Get started
Home
csci 363 midterm review
csci 363 midterm review
0.0
(0)
Rate it
Studied by 0 people
View linked note
Learn
Practice Test
Spaced Repetition
Match
Flashcards
Card Sorting
1/36
There's no tags or description
Looks like no tags are added yet.
Study Analytics
All
Learn
Practice Test
Matching
Spaced Repetition
Name
Mastery
Learn
Test
Matching
Spaced
No study sessions yet.
37 Terms
View all (37)
Star these 37
1
New cards
Single Responsibility Principle (SRP)
A class should have only one reason to change.
2
New cards
Open/Closed Principle (OCP)
Classes should be open for extension but closed for modification.
3
New cards
Liskov Substitution Principle (LSP)
Subtypes must be substitutable for their base types.
4
New cards
Interface Segregation Principle (ISP)
A class should not be forced to implement interfaces it doesn’t use.
5
New cards
Dependency Inversion Principle (DIP)
High-level modules should depend on abstractions, not concrete implementations.
6
New cards
Encapsulation
Restricting direct access to object data while exposing necessary parts.
7
New cards
Inheritance
Uses 'is-a' relationships.
8
New cards
Composition
Uses 'has-a' relationships.
9
New cards
Abstraction
Hiding implementation details while exposing only essential functionality.
10
New cards
Singleton pattern
Ensures only one instance of a class exists.
11
New cards
Factory Method pattern
Encapsulates object creation, letting subclasses decide which class to instantiate.
12
New cards
Abstract Factory pattern
Creates families of related objects without specifying concrete classes.
13
New cards
Builder pattern
Separates object construction from representation by building it step by step.
14
New cards
Adapter pattern
Converts one interface into another to make incompatible systems work together.
15
New cards
Bridge pattern
Separates abstraction from implementation.
16
New cards
Flyweight pattern
Shares objects to reduce memory usage.
17
New cards
Strategy pattern
Encapsulates multiple interchangeable behaviors.
18
New cards
Observer pattern
Defines a dependency where multiple objects listen and react to changes in a subject.
19
New cards
Command pattern
Encapsulates a request as an object, allowing parameterization, queuing, and logging.
20
New cards
State pattern
Allows an object to change behavior when its internal state changes.
21
New cards
Chain of Responsibility pattern
Passes a request through a chain of handlers until one processes it.
22
New cards
Strategy vs State patterns
Strategy lets the client choose the behavior; State changes behavior based on internal state.
23
New cards
When to use Observer pattern
When multiple objects need to react to state changes in a subject.
24
New cards
Chain of Responsibility pattern flexibility
Requests are passed through multiple handlers, allowing different handlers to process them dynamically.
25
New cards
Builder pattern benefits
Helps construct complex objects while keeping the creation process flexible.
26
New cards
When to use Adapter pattern
When you need to make an existing class compatible with another interface.
27
New cards
Fixing Singleton thread safety
Use synchronized getInstance() or double-checked locking.
28
New cards
Primary benefit of the Bridge pattern
Decouples abstraction from implementation.
29
New cards
How Command pattern aids in undo/redo
Commands can be stored in a history log, allowing undo and redo operations.
30
New cards
Flyweight pattern drawback
Managing shared state can be complex.
31
New cards
Factory Method and Open/Closed Principle
New types can be added without modifying existing code.
32
New cards
Observer pattern coupling
Subjects and observers are loosely coupled.
33
New cards
Tight vs Loose coupling
Tight coupling makes changes harder, while loose coupling improves flexibility.
34
New cards
High cohesion
A class focuses on a single responsibility, making it easier to maintain.
35
New cards
Low cohesion
A class has multiple unrelated behaviors, making it difficult to maintain.
36
New cards
Aggregation vs Composition
Aggregation is a weak relationship; composition is a strong relationship where the contained object cannot exist independently.
37
New cards
Composition preference over inheritance
It avoids deep inheritance hierarchies and helps achieve loose coupling.