What is displayed by the following program after the call to pthread_create?
#include
#include
void *thread(void *);
int main()
{
pthread_t tid;
pthread_create(&tid, NULL, thread, NULL);
cout << "After pthread_create" << endl;
return 0;
}
void *thread
(void *argument)
{
return NULL;
}
a. The main thread will display "After pthread_create"
b. The new thread will display "After pthread_create"
c. Neither the main thread nor the new thread will display "After pthread_create"
d. The program does not create a new thread
e. Both the main thread and new thread will display "After pthread_create"
a. The main thread will display "After pthread_create"
You might also like to view...
Data CANNOT be exchanged between Access and Excel
Indicate whether the statement is true or false
As applied within the EBK, a(n) ____________________ encompasses a given set of roles.
Fill in the blank(s) with the appropriate word(s).