Bird
0
0

What is true about an abstract method in Java?

easy📝 Conceptual Q1 of 15
Java - Abstraction
What is true about an abstract method in Java?
AIt has no body and must be implemented by subclasses.
BIt can be called directly without an object.
CIt must have a body in the abstract class.
DIt cannot be overridden by subclasses.
Step-by-Step Solution
Solution:
  1. Step 1: Understand abstract method definition

    An abstract method is declared without a body and forces subclasses to provide implementation.
  2. Step 2: Analyze options

    Only It has no body and must be implemented by subclasses. correctly states that abstract methods have no body and must be implemented by subclasses.
  3. Final Answer:

    It has no body and must be implemented by subclasses. -> Option A
  4. Quick Check:

    Abstract method = no body, must implement [OK]
Quick Trick: Abstract methods have no body and require subclass implementation [OK]
Common Mistakes:
  • Thinking abstract methods can have a body
  • Assuming abstract methods can be called directly
  • Believing subclasses cannot override abstract methods

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Java Quizzes