A mutex is a mutual exclusion lock. When a mutex is held by one [threads%|%thread], it prevents other threads from gaining hold of the mutex. The [thread] [package] also supports a [thread::rwmutex%|%read-write “mutex”], which allows many readers to hold the mutex at once, but when some writer thread wants the mutex, it waits to gain it exclusively. <>Concurrency | Concept