What is the use of threads ? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson

What is the use of threads ?

I didn't quite understand why we use it

2nd Aug 2016, 2:50 PM
xzys - avatar
3 Answers
Threads allow the computer to be sent information in a faster, cleaner manner. Multi threading speeds up programs.
4th Aug 2016, 5:13 PM
Mitch K
Mitch K - avatar
threads are light weight processes they share memory address with other threads and requires less resources
6th Aug 2016, 4:40 PM
sachin tomar
sachin tomar - avatar
Threads are used to let your program utilize several CPU cores or let your program run multiple tasks in parallel. If you have a quad-core processor, you can use all 4 cores by using 4 threads to carry out tasks for you. (Note that you have to split up your program and run different parts of your program in each thread in order to use this advantage)
1st Oct 2016, 1:02 PM
Adrian Nesse Wiik
Adrian Nesse Wiik - avatar