Java OCA OCP Practice Question 2174

Question

When extending the Thread class to implement the code executed by a thread, which method should be overridden?

Select the one correct answer.

  • (a) begin()
  • (b) start()
  • (c) run()
  • (d) resume()
  • (e) behavior()


(c)

Note

When extending the Thread class, the run() method should be overridden to provide the code executed by the thread.

This is analogous to implementing the run() method of the Runnable interface.




PreviousNext

Related