Multithreading:-

Definition:- A thread in java a single task is called a thread. A thread is similar to a program that has a simple flow of control. The term "thread" refers to a "thread of control" or "thread of execution", meaning a sequence of instructions that are executed one after another the thread extends through time, connecting each instruction to the next. In a multithread program, there can be many threads of control weaving through time in parallel and performing the complete fabric of the program.
Every java program has at least one thread; when the java virtual machine runs your program it creates a thread that is responsible for executing the main routine of the program. This main thread can in turn create other threats that can continue even after the main thread has terminated.

Comments

Popular posts from this blog

Write a program to add two number using inline function in C++?

Traversing of elements program with algorithm and Flowchart