Open MP - reduction and parallel `for-loop`

Let’s now try to understand how to parallelize a simple for loop using OpenMP. For example, we want to sum-up all the numbers from 1-12, but using 3 threads in parallel. Let’s observe the following figure

Get hands-on with 1000+ tech skills courses.