Thread.start() method in java

Thread.start() creates new thread which is responsible for the execution of run() method. Thread.start() is also responsible to register a thread with thread scheduler.

Importance of Thread.start()?

In java, there is no other way to start a new thread. Only Thread.start() creates new thread which is responsible for the execution of run() method. Thread.start() is also responsible to register a thread with thread scheduler. That’s why, Thread.start() is consider as Heart of Multi-threading.

Overriding start() / Overriding Thread.start()

If we override a Thread.start() method, it will not create a new thread. It will act as normal method.

Output:

Difference between start() and run() in Java?

Thread.start() creates new thread which is responsible for the execution of run() method. Thread.start() is also responsible to register a thread with thread scheduler.
Thread.run() method won’t create new thread and just act as normal method.

Help others by sharing the content!

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.