// #include #include #include #include #include int GlobV = 0; void* action (void* increment) { for (i=1 ; i<= NOMBRE; i++) globV = globV + *increment; return 0; } int main (int argc; char* argv[]) { pthread_t unThread; int valeur; assert (argc == 2); valeur = atoi(argv[1]; if (pthread_create(&unThread, NULL, action, &valeur) { perror("pthread_create"); exit(-1); } } printf("\nmain : globV = %d \n\n", globV) ; return (0); }