Suppose i have two threads t1 and t2 are running.How the
main thread will know that the two threads t1,t2 execution
has completed?

Answers were Sorted based on User's Feedback



Suppose i have two threads t1 and t2 are running.How the main thread will know that the two threads..

Answer / satishkumar vishwakarma

with the help of isAlive() and join() method.
The isAlive returns true when threads are running and
join() will wait till the execution get completed.

Is This Answer Correct ?    58 Yes 1 No

Suppose i have two threads t1 and t2 are running.How the main thread will know that the two threads..

Answer / fellow java novice

use join

Is This Answer Correct ?    9 Yes 19 No

Post New Answer

More Core Java Interview Questions

What is the purpose of format function?

0 Answers  


suppose string s1="rajnish"; string s2="bhaskar"; then what will be happend ?

9 Answers   Fidelity,


What is rmi and steps involved in developing an rmi object?

0 Answers  


In Java list the methods that can be overridden?

0 Answers   Accenture,


How to sort numbers in java without array?

0 Answers  






What method is used to compare two strings ?

4 Answers  


Is empty list java?

0 Answers  


Marker interface means , interface which has no methods.Then what is the necessity of its usage.I read "it tells the compiler that it should be treated differently ". "It is used to store state of an object". But still am not clear.Please explain clearly.

2 Answers  


What is hashmap in java?

0 Answers  


What is object

6 Answers  


How do you control extraneous variables?

0 Answers  


In Inheritance if we are implementing Multi level inheritance and all class having same name of variable and now i want to access each class variable and how it is possible?

2 Answers  


Categories