How many types of thread in java? give the name

Answer Posted / shekhar

There are two types of threads in java....

1. User threads: Which are created by the user program
itself. The example is the Main thread etc...

2. Daemon Threads: These threads are generated by the JVM
itself. They are service provider threads which run in the
background and are not used to run the application code.
The example is the Garbage Collection thread.

Is This Answer Correct ?    28 Yes 9 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the reason behind using constructors and destructors?

558


Is void a type?

583


How do you add an element to an arraylist in java?

487


Can we access instance variables within static methods ?

567


How is hashset defined in java?

517






What is a values collection view ?

681


What is the Scope of Static Variable?

729


Is 0 a prime number?

572


Can a static member function access member variable of an object?

558


What are the fileinputstream and fileoutputstream?

568


What are classloaders?

599


What does \ mean in regex?

621


Why a dead thread occurs?

573


What is the java reflection api? Why it’s so important to have?

553


Can an object be null?

547