Bird
0
0

Which software engineering principle encourages writing code that does one thing and does it well?

easy📝 Conceptual Q11 of 15
Software Engineering - Fundamentals
Which software engineering principle encourages writing code that does one thing and does it well?
AOpen/Closed Principle
BDon't Repeat Yourself (DRY)
CSingle Responsibility Principle (SRP)
DKeep It Simple, Stupid (KISS)
Step-by-Step Solution
Solution:
  1. Step 1: Understand the principle names

    SRP means each module or class should have one responsibility or reason to change.
  2. Step 2: Match the description to the principle

    Writing code that does one thing well matches SRP.
  3. Final Answer:

    Single Responsibility Principle (SRP) -> Option C
  4. Quick Check:

    One responsibility = SRP [OK]
Quick Trick: One job per module means SRP [OK]
Common Mistakes:
  • Confusing SRP with DRY which avoids repetition
  • Thinking KISS means single responsibility
  • Mixing Open/Closed with SRP

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Software Engineering Quizzes