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
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 |
what is finalmethod & final variable with example?
Can we override private methods?
How to perform linear search in java?
What is continuity of a function?
What's the access scope of protected access specifier?
What are the two parts of a conditional statement?
What is immutability in java?
How do you create a first line indent?
What is blank final variable?
What is a class ?
When a thread is executing synchronized methods , then is it possible to execute other synchronized methods simultaneously by other threads?
Why should we use singleton pattern instead of static class?