MCQ
Where can methods be defined in Java?
  • A
    In subclass
  • Inside a class
  • C
    Outside of the class
  • D
    Is not possible

Answer

Correct option: B.
Inside a class
Inside a class

Need a full question paper?

Generate a complete, print-ready paper with questions like this in minutes — across 16+ boards, with answer keys.

Start Generating Free