Loading lesson…
Level 1 · Apprentice0 XP
Threads, channels, Send and Sync, and data parallelism with rayon.
Step 1 / 6
ProblemIn many languages, two threads updating a map without a lock corrupt it once in a million runs. The bug appears in production and never in tests.
← → step
Before this: Smart pointers: Box, Rc, Arc, RefCell and Mutex
🛠️ Your turn
Reading is not the skill, doing is. Try for ten minutes before you open the hint. Getting stuck first is what makes the solution stick.
1.Count words in every file of a large folder three ways: a single thread, threads with a channel, and rayon par_iter. Time each and explain the results.