good job man. nice brief summarisation and good articulation than lot of other multithreading videos, which are either too verbose, or too slow, or too digressing with not-that-straight examples, or not articulated well enough. Thanks a lot!! for the free service.
The thread stack also contains all local variables for each method being executed (all methods on the call stack). A thread can only access it's own thread stack. Local variables created by a thread are invisible to all other threads than the thread who created it. Even if two threads are executing the exact same code, the two threads will still create the local variables of that code in each their own thread stack. Thus, each thread has its own version of each local variable. All local variables of primitive types (boolean, byte, short, char, int, long,float, double) are fully stored on the thread stack and are thus not visible to other threads. One thread may pass a copy of a pritimive variable to another thread, but it cannot share the primitive local variable itself.
The canteen has two windows for rice. (window 1 and window 2), each window has a master to provide meal service, and the window service time is as follows. Master a of window 1 is preferred to start the service. After cooking for three students, open window 2 and master B of window 2 starts the service. The total number of students is 30. Please describe the code implementation with multithreading mechanism. who can solve it?
Asynchronous execution mechanism is defined wrong in the yellow highlighted box as it’s not capable of running in background but asynchronous means not waiting for the other thread to complete and execute simultaneously.
I think your last example explanation is not correct. Thread.wait() is not used when you want to wait the completion of that thread but you use it on any object (not only thread) whose lock thread needs to give up so that other thread can lock it and then again acquire it back to complete the rest of the part. If you want to continue execution of thread after completion of other thread, then you need to use join() on that thread
how two thread can override the method argument value,every thread have own stack and method argument and local variable is maintained in the stack, can you please provide example and demonstrate, two thread can overide the local variable and share in between
The last example the wait and notify are called by locking on different object.. not a good practice as you may miss a signal !! Also in the last example you could have simply used join. Not an amazing example to show wait and notify ...
communication will be a big problem in that case. For ex while notifying you need to know all the threads who are waiting and call method on each of them. Object helps in that sort of communication.
Very short explanations with no significant terminologies used. Its okay to keep it brief but should highlight important aspects else it not much of a use. Felt same with Design Pattern videos.
Voice not good sir.use indian English and in udemy plese provide along with your bord explanation video.not always eclipse focus on camera not good.and plese tell clarify sir.clarfication not reached
Wow..Amazing Tutorial..Clear, covers a lot yet concise enough!
good job man. nice brief summarisation and good articulation than lot of other multithreading videos, which are either too verbose, or too slow, or too digressing with not-that-straight examples, or not articulated well enough. Thanks a lot!! for the free service.
The thread stack also contains all local variables for each method being executed (all methods on the call stack). A thread can only access it's own thread stack. Local variables created by a thread are invisible to all other threads than the thread who created it. Even if two threads are executing the exact same code, the two threads will still create the local variables of that code in each their own thread stack. Thus, each thread has its own version of each local variable.
All local variables of primitive types (boolean, byte, short, char, int, long,float, double) are fully stored on the thread stack and are thus not visible to other threads. One thread may pass a copy of a pritimive variable to another thread, but it cannot share the primitive local variable itself.
Because objects are reference pointers to memory structures, potentially shared, while primitives are "values"
Great Content, Can say that this video cleared my all doubts and all topics are clear now.
Really Helpful video Sir,Thank You :)
Well done!
The canteen has two windows for rice. (window 1 and window 2), each window has a master to provide meal service, and the window service time is as follows. Master a of window 1 is preferred to start the service. After cooking for three students, open window 2 and master B of window 2 starts the service. The total number of students is 30. Please describe the code implementation with multithreading mechanism.
who can solve it?
Asynchronous execution mechanism is defined wrong in the yellow highlighted box as it’s not capable of running in background but asynchronous means not waiting for the other thread to complete and execute simultaneously.
I am 100% impressed
great video
great video. if i'm not mistaken, Future object would be derived from callable instead of runnable
Where we can find your generics exercises code which you mentioned in Video? on GIT HUB?
Excellent
Amazing example
Thanks sir!!!!!!!!!!!!!!!!
This is gold!!!
I think your last example explanation is not correct. Thread.wait() is not used when you want to wait the completion of that thread but you use it on any object (not only thread) whose lock thread needs to give up so that other thread can lock it and then again acquire it back to complete the rest of the part.
If you want to continue execution of thread after completion of other thread, then you need to use join() on that thread
Well done.
"Threads allow java code to run in parallel". That is not true. Parallelism is not guaranteed in java multithreading. Only concurrency.
Where we can find these documents? Please share the link.
🔥🔥🔥🔥🔥🔥🔥🔥🔥🔥
Thanks a lot!
Where we can find your multithreading & generics exercises code ?
Very well explained in detail. Where can I get the source code?
I found it at: github.com/in28minutes/JavaInterviewQuestionsAndAnswers
@@johncanessa2250 this link dosent work for me 😔
What if we will commented out the notify() from the Calculator class ?
then main method continues to wait infinitly eventhough another thread is completed and thread.sum will never be executed
Excellent video
Why the Thread that will provide us the bowling statistics is called "battingThread2" ? Shouldn't we call it "bowlingThread"?
It's just naming convention, you can give whatever you want. BTW best practice we should have "bowlingThread" as you suggested.
how two thread can override the method argument value,every thread have own stack and method argument and local variable is maintained in the stack, can you please provide example and demonstrate, two thread can overide the local variable and share in between
Can u provide this PDF link ?
Where can we donwload a complete pdf or ppt file with all the explanations of each question?
Tysm
source code of the eg?
The last example the wait and notify are called by locking on different object.. not a good practice as you may miss a signal !!
Also in the last example you could have simply used join. Not an amazing example to show wait and notify ...
One big question why wait and notify methods in object class not in thread class?
communication will be a big problem in that case. For ex while notifying you need to know all the threads who are waiting and call method on each of them. Object helps in that sort of communication.
wow
Very short explanations with no significant terminologies used. Its okay to keep it brief but should highlight important aspects else it not much of a use. Felt same with Design Pattern videos.
People starting complaining about video..... they don't know that Video title is Interview questions and ans.
@21:45 you have called wait method as Thread.wait(); which is incorrect wait method belongs to Object class not to Thread class
From where can I get the full document which you are going through in the video?
He does courses on Udemy , I got a few for discounted price and they are very good :)
Voice not good sir.use indian English and in udemy plese provide along with your bord explanation video.not always eclipse focus on camera not good.and plese tell clarify sir.clarfication not reached
Hi I was 70k th sub can I win prize? I like your videos thanks!
What prize you wanna win?
moving screen up and down is very annoying. need to focus on presentation more
Exaplaination is not good
Where we can find your generics exercises code which you mentioned in Video? on GIT HUB?
yeah