This repository contains practical, easy-to-understand examples of common Object-Oriented Design Patterns implemented in C# (.NET). It serves as a reference for software engineers looking to learn, review, or demonstrate design patterns in real-world scenarios.
- β Clean and readable C# implementations
- π Each pattern in its own directory
- π§± Covers all three major pattern types:
- Creational (e.g., Singleton, Factory, Abstract Factory, Builder)
- Structural (e.g., Adapter, Composite, Proxy, Decorator)
- Behavioral (e.g., Strategy, Observer, Command, Visitor)
- Singleton
- Factory Method
- Abstract Factory
- Builder
- Prototype
- Adapter
- Bridge
- Composite
- Decorator
- Facade
- Proxy
- Flyweight
- Chain of Responsibility
- Command
- Interpreter
- Iterator
- Mediator
- Memento
- Observer
- State
- Strategy
- Template Method
- Visitor
More patterns may be added over time.
Whether you're preparing for interviews, reinforcing your design skills, or building scalable systems, understanding design patterns is essential. These examples are structured to be minimal, focused, and idiomatic to C#.
Clone the repo and open it with Visual Studio or Rider:
git clone https://github.com/saeedahmadi694/my-design-patttern-examples.git