Day 18/100 100 Days of Code


Concurrency is a feature that is not aimed at beginner developers. It is important to understand it properly as it can be very confusing and cause problems that might be difficult to understand.

I hit a brick wall during the development of Info Hunter due to my limited understanding of concurrency.

So, I spent the session watching a tutorial about mutex which is an object that can be used to control the flow of the multithreaded operation in critical sections.

A thread "locks" or "unlocks" sections that are critical to an operation. This means that data that is shared between threads won't be used by all the threads at the same time. Each thread will wait until the previous thread completes its operations.

Special thanks to CppNuts for the great tutorials on multithreading.