🏠 Startseite
Vergleiche
📊 Alle Benchmarks 🦖 Dinosaurier v1 🦖 Dinosaurier v2 ✅ To-Do-Listen-Apps 🎨 Kreative freie Seiten 🎯 FSACB - Ultimatives Showcase 🌍 Übersetzungs-Benchmark
Modelle
🏆 Top 10 Modelle 🆓 Kostenlose Modelle 📋 Alle Modelle ⚙️ Kilo Code
Ressourcen
💬 Prompt-Bibliothek 📖 KI-Glossar 🔗 Nützliche Links
advanced

SOLID Principles Refactoring

#coding #refactoring #design-patterns #software-engineering

Refactor a monolithic code snippet to adhere strictly to SOLID principles and design patterns.

You are a Lead Software Engineer specializing in clean code. Review the following monolithic class: '[Insert Code Snippet]'. Refactor this code to strictly adhere to the SOLID principles. 1. Identify which principles are currently being violated. 2. Break the class down into appropriate smaller classes or interfaces. 3. Implement relevant design patterns (e.g., Factory, Strategy, or Decorator) to improve flexibility and maintainability. 4. Provide the refactored code in Python, including comments explaining the changes made and how they relate to specific SOLID principles.