Q: The statement that brings the control back to the calling method is:
-
A
break
-
B
System.exit(0)
-
C
continue
-
D
return
D
Answer:
D
Explanation:
The statement that brings the control back to the calling method:
-
break → exits a loop or switch, but control does not go to the calling method.
-
System.exit(0) → terminates the entire program.
-
continue → skips the current iteration of a loop, but stays inside the loop.
-
return → exits from the current method and returns control to the calling method. ✅
Answer: (d) return
Related Topic:
Share Above MCQ