what is the difference between sleep() and Wait()?
Answer Posted / vinay kumar
sleep() will wait go to sleep for amount of time that is specified in it.After the times finishes it resumes automatically.
wait() will also wait for some I/O and will NOT resume automatically but will resume only when notify() or notifyall() is called.
| Is This Answer Correct ? | 19 Yes | 7 No |
Post New Answer View All Answers
What is a qualifier in a sentence?
What is garbage collector?
Do you know why doesn't the java library use a randomized version of quicksort?
What are user defined exceptions?
Why is multithreading important?
what do you mean by marker interface in java?
Can we define package statement after import statement in java?
What do you mean by stream pipelining in java 8?
What are the advantages of java over cpp?
Will set allow duplicates in java?
explain autoboxing in java?
what is enumset?
How do you reverse a string in java?
What is method overloading in JAVA? Why is it not present in C ?
Is java call by reference?