Why Use Threads?
This lesson discusses two major reasons for the use of threads.
We'll cover the following...
Before getting into the details of threads and some of the problems you might have in writing multi-threaded programs, let’s first answer a more simple question. Why should you use threads at all?
Press + to interact
As it turns out, there are at least two major reasons you should use threads.
Parallelism
The first is simple: parallelism. Imagine you are writing a program that performs operations on very large arrays, for example, adding two large arrays together, or incrementing the value of each ...