In the previous recipe, we saw how data can be shared between the main thread and a single worker. This is helpful for move long-running operations on the main thread, which helps keep the UI responsive. However, it isn't taking full advantage of parallel processing. With very large datasets, breaking up the computation between many workers can be advantageous.
In this recipe, we'll see how to use multiple workers to produce portions of a result.