-

Decorator
Decorator is a structural design pattern that lets you attach new behaviors to objects by placing these objects inside special wrapper objects that contain the behaviors.
-

Bridge
Bridge is a structural design pattern that lets you split a large class or a set of closely related classes into two separate hierarchies—abstraction and implementation—which can be developed independently of each other.
-

-

-

Observer
Bir abonelik sistemi oluşturup. Bazı değişimlerin, bazı gözlemcilere bildirilmesidir. Temel amaç gereksiz sorgulamaların ve bilgi gönderimlerinin önüne geçmek. Observer is a behavioral design pattern that lets you define a subscription mechanism to notify multiple objects about any events that happen to the object they’re observing. Imagine that you have two types of objects: a Customer and a Store. The customer…
-

Memento
Memento is a behavioral design pattern that allows making snapshots of an object’s state and restoring it in future. The Memento doesn’t compromise the internal structure of the object it works with, as well as data kept inside the snapshots.
-

Command
Command is a behavioral design pattern that turns a request into a stand-alone object that contains all information about the request. This transformation lets you pass requests as a method arguments, delay or queue a request’s execution, and support undoable operations.
-

Chain of Responsibility
Bir geri dönüşüm fabrikasındaki bantı düşünün. Bir nesne, banttan geçerken tipine ve şeklinde göre işçiler tarafından ayıklanır. Şöyle yapalım. Chain of Responsibility (Sorumluluk zinciri) buna benzer bir şekilde çalışır. Karpuzların elden ele taşınması gibi nesneler, handlerdan handler’a taşınır. Tek fark eğer handler nesneyi kullanabiliyorsa onu alıp kullanır. Yoksa sonraki handler a atar.
-

Factory & Abstract Factory
Bir nesnenin contruction işlemi için özel bir sınıf oluşturduysak bu factory method oluyor. Atıyorum koltuk üretmek için new koltuk(); çağrısı yapmaktan ziyade KoltukFabrikası(“koltuk”); gibi bir çağrı yapıyorsak bu factory methodu oluyor. Peki tek tip bir koltuğum yoksa ne olacak. Farklı stiller için aynı fabrikayı mı kullanmalıyım? Farklı stiller için farklı fabrikalar kullanabiliriz: KoltukFabrikası() nı abstract…
-

Builder
Tanım Birçok parametrenin ayarlanması gereken bir sınıfı oluşturmak için karmaşık constructorlar kullanmak yerine daha esnek yardımcı bir sınıf kullanmak. C++ implementasyonu
-

Singleton
Tanım Creational Design Pattern’dır. Programımızda sadece ve sadece 1 tane bulunmasını istediğimiz nesneler için bu kalıbı kullanıyoruz. Bunu yapmak için sınıfın constructor’ını gizleyip statik bir method üzerinden statik bir pointer aracılığıyla nesneye erişiyoruz. C++ implementasyonu Daha fazla kaynak https://refactoring.guru/design-patterns/singleton
-

Dual Boot Klavye Eşleştirmesi
Kaynak: https://gist.github.com/madkoding/f3cfd3742546d5c99131fd19ca267fd4 1) Pair ALL bluetooth devices in linux (it is to have the files you will need to edit later) 2) Pair ALL bluetooth devices in Windows 10. If you know how, get the MAC address id from your bluethooth keyboard, we will need it later 3) Reboot and go back to Linux 4)…
-

-

-

-

Tonelli–Shanks Algorithm
The Tonelli–Shanks algorithm (referred to by Shanks as the RESSOL algorithm) is used in modular arithmetic to solve for r in a congruence of the form r2 ≡ n (mod p), where p is a prime: that is, to find a square root of n modulo p. m sıralı çiftleri II koordinata göre sıralanarak listesi oluşturulur. olmak üzere, hesaplanır. m sıralı çiftleri II. koordinata göre sıralanarak listesi oluşturulur. bulunur
