Here you can find implementations of different data structures, algorithms, and design patterns:
-
Data structures:
- Lists
- Static array
- Dynamic array
- Singly linked list
- Double linked list
- Stack
- Queue
- Binary trees
- Non-binary trees
- Internal sorting
- File processing
- External sorting
- Searching
- Indexing
- Divide and Conquer
- Graphs
- Lists
-
Algorithms
-
Design patterns (26):
- Creational:
- Factory method (class)
- Abstract factory
- Builder
- Prototype
- Singleton
- Object pool
- Structural:
- Adapter class (class)
- Adapter object/Private class data
- Bridge
- Composite
- Decorator
- Facade
- Flyweight
- Proxy
- Behavioral:
- Interpreter (class)
- Template method (class)
- Chain of responsability
- Command
- Iterator
- Mediator
- Memento
- Observer
- State
- Strategy
- Visitor
- Null object
- Creational:
Running time complexity of each method is specified in-code next to the method using O-notation (i.e., upper bound) for the worst case. If it's O(1), it's not specified.
The code is under the namespace dsa
(for Data Structures and Algorithms).
- Data structures & Algorithm analysis
- The Gang of Four (1994) Design patterns. Elements of reusable object-oriented software. Addison-Wesley.