Microsoft Interview Question

After implementing the above algorithm, how to perform parallelized computation