13.3 Multithreading using Runnable Interface

preview_player
Показать описание
In computer science, a thread of execution is the smallest sequence of programmed instructions that can be managed independently by a scheduler, which is typically a part of the operating system.
Multithreading in java is a process of executing multiple activities can proceed concurrently in the same program.
Thread is basically a lightweight sub-process, a smallest unit of processing.
In multithreading threads share a common memory area.
They don't allocate separate memory area so saves memory, and context-switching between the threads takes less time than process.

Multiple threads can exist within the same process and share resources such as memory, while different processes do not share these resources.
Using two different task at the same time means multi-tasking. Thread is unit of a process.

Check out our courses:

Coupon: TELUSKO10 (10% Discount)

Coupon: TELUSKO10 (10% Discount)

Coupon: TELUSKO10 (10% Discount)

Coupon: TELUSKO20 (20% Discount)

Udemy Courses:

For More Queries WhatsApp or Call on : +919008963671

Subscribe to our other channel:
Telusko Hindi :

Subscribe to the channel and learn Programming in easy way.

Рекомендации по теме
Комментарии
Автор

prefect he is really smart talking and not make you feel sleepy he knows how to deal with record voice

sumrjd
Автор

Hi Naveen Reddy garu,
Please make a video on complete collections.
U have so much knowledge in java and superb explanation.Every one will understand your videos.

vijayvantela
Автор

I'm watching this after 5 years and it still helped me a lot!

kahanx
Автор

No words to describe about your teaching 👏👏👏👏👏👏👏

patteboyinadharani
Автор

the way of teaching is really understandable in all the videos.... thank you so much. and the beginning music also nice !!!

cael_
Автор

Thank you, Sir!!!
This helps a lot for me.

bellewolde
Автор

wow u hav clarity!!n i love people who hav clarity in their

abufaya
Автор

4:04 Hi Hello was sounding like "Hi Hiku Hi Hiku, hi hi...", btw your teaching is the best.

avinashmodi
Автор

Very easy to understand java when you teach us sir

manandesai
Автор

Excellent Videos offered by you . keep going on

Sudarshan-Advocate-Labrador
Автор

Hi, how can we implement thread in spring projects, please provide the exact real time scenario. Thanks

sengottaiyanperiyasamy
Автор

Great job sir u r videos are very helpful

sreenivask
Автор

Why we are using the reference of runnable? Can we use interfaces to refer objects? Why? Please tell me 3:42

gladyouseen
Автор

I have a query, we cannot make object of an interface then why is it written -> 'Runnable' obj1 = new Hi(); or 'Runnable' obj2 = new Hello();

rajshreegavel
Автор

@Telusko Hi! How did you go to the declaration of the interface runnable at 0:47? Which shortcut did you use? Kindly tell me how to see the documentation using that keyboard shortcut?

vibhorsteele
Автор

Wow that's really well explained! Thanks man

ValatY
Автор

Ah sir can we have some more videos on Runnable and multithreading please :)

shyamkachhadiya
Автор

Sir, why cant we simply write

obj1.run();


instead of,


Thread t1 = new Thread(obj1);
t1.show();

simplelife
Автор

i have a doubt.What is the difference between "different threads with different instance of the class and different threads with the same instance of the class" ?

nakulvs
Автор

what is the difference between an abstract class and an interface if have two methods in getting a thread

raghavenderraosaini