Skip to Content
Mastering Functional Programming
book

Mastering Functional Programming

by Anatolii Kmetiuk
August 2018
Intermediate to advanced
380 pages
10h 2m
English
Packt Publishing
Content preview from Mastering Functional Programming

Problems with the traditional model – race conditions and deadlocks

The problems start to appear when more than one resource gets involved. Consider, for example, a slightly modified version of the preceding program. In the previous example, we had to write the result of the computation into a file. Consider that, at the same time as doing the computations themselves, we need to keep track of what they're doing in a log file. This kind of practice can be useful in a real-world scenario for debugging purposes.

So, the plan is as follows. First, the entire input file is read into the program memory. In our current scenario, threads are heterogeneous, which means that they have different tasks to accomplish. Homogeneous threads are generally ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Learning Functional Programming

Learning Functional Programming

Jack Widman

Publisher Resources

ISBN: 9781788620796Supplemental Content