๐Ÿ“ข Too many exams? Donโ€™t know which one suits you best? Book Your Free Expert ๐Ÿ‘‰ call Now!

  • google app store apple app store
  • โœ–

      Question

      What does the "L" in SOLID principles stand for?

      A Liskov Substitution Principle Correct Answer Incorrect Answer
      B Lasting Structure Principle Correct Answer Incorrect Answer
      C Logical Separation Principle Correct Answer Incorrect Answer
      D Layered Architecture Principle Correct Answer Incorrect Answer
      E Limitations Principle Correct Answer Incorrect Answer

      Solution

      The "L" in SOLID principles stands for the Liskov Substitution Principle (LSP), which states that objects of a superclass should be replaceable with objects of a subclass without affecting the correctness of the program. In other words, if class B is a subclass of class A, then an instance of B should be able to replace an instance of A without altering the desirable properties of the program (correctness, task performed, etc.). This principle encourages proper inheritance and ensures that derived classes extend the functionality of base classes without altering expected behavior, promoting code reusability and robustness. Option B (Lasting Structure Principle) is incorrect as there is no such principle within SOLID. Option C (Logical Separation Principle) does not exist as a recognized design principle. Option D (Layered Architecture Principle) is a valid architectural concept but not part of SOLID principles. Option E (Limitations Principle) is also not a recognized principle in software engineering.

      Practice Next

      Relevant for Exams:

      ask-question