Multithreading at a Glance - Part 1
H ello Techie's, How are you all? Hope you are doing well in life. My name is " Sumit Srivastava " and I am MCA passout of 2019 batch. I have taken Multithreading as today's topic. So, let's go. Multi-threading Guy's before moving to Multithreading , first we should know about what the Thread is? A Thread is a lightweight sub-process . It a a smallest part of process which allows to operate any task in a efficient way without interacting to any other thread. It means a thread is independent in nature. Thread We can create a thread in two ways:- 1. by extending Thread class 2. by implementing Runnable Interface. Ex.1 By extending Thread class - public class Test extends Thread{ public void run(){ System.out.println("Thread are in run method by extending thread class"); } } Ex.2 By implementing Runnable Interface - public class Test im...