how to install and run the simple code on MinGW through GCC for Pthread coding
Prerequisite: MinGW need to installed Install GCC on MinGW : pacman -Syu gcc After successful installation you will require to create the C file on notepad++ or in any of the file editor. Paste below mention code into the file and save it with .c extension. Code: file name is hello.c # include <omp.h> # include <pthread.h> # include <stdio.h> # include <stdlib.h> void * print_hello ( void *thrd_nr) { printf ( "Hello World. - It's me, thread #%ld\n" , ( long )thrd_nr); pthread_exit( NULL ); } int main ( int argc, char *argv[]) { printf ( " Hello C code!\n" ); const int NR_THRDS = omp_get_max_threads(); pthread_t threads[NR_THRDS]; for ( int t= 0 ;t<NR_THRDS;t++) { printf ( "In main: creating thread %d\n" , t); pthread_create(&threads[t], NULL , print_hello, ( void *)( long )t); } for ( int t= 0 ;t<NR_THRDS;t++) { pthread_join(threads[t], NULL ); } printf ( "A...