What is the life cycle of Thread ?

Answer Posted / harmeet

1.create the thread on which object u want, using Thread
interface,
2.then use obj.start() to invoke the thread
3.this method will intern call run() of Thread class
4.once it's serviced, it will come to dead state.

Is This Answer Correct ?    18 Yes 16 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the purpose of the file class in java programming?

520


How do you get the length of a string in java?

516


How are java objects passed to a method and what are native methods?

585


Can we override static methods in java?

575


Are true and false keywords?

560






what do you mean by stream pipelining in java 8? Explain

526


What are the differences between this and super keyword?

525


How do you remove duplicates from an array in java?

524


How big is a gigabyte?

609


Can we override the static methods?

560


How to sort an array in java without using sort method?

521


How do you do absolute value in java?

520


What was java originally called?

503


How to find the index of the largest number in an arraylist java?

512


When do we need to use internal iteration? When do we need to use external iteration?

599