A console application for simulating multi-threading programme in C language.
- Clone the code for your pc (Linux environment is best)
git clone https://github.com/srimalonline/pthreads-in-c
cd pthreads-in-c
To know the correct execution time, I'm using WSL ubuntu environment with windows terminal. So, You should use linux environment and install gcc package.
- Compile the app using gcc (adding -lpthread is a must)
gcc app.c -lpthread
Then you just created an executable file named a.out
- Run the executable file with time function.
time ./a.out
Platform: Linux/ Windows with WSL
Package: gcc
- @srimalonline Thanks