linked linked linkedin whatsapp remove
Feedback

System Programming Quiz System Programming

The following code is written to be accessed by multiple detached threads. : const char * c; char * d; : /* no lock and no mutex is used in any way here */ my_print_func (c, &d); : Which one of the following will happen when this code is re-entered by multiple threads?

The code will sometimes run and sometimes cause a crash
The code will always cause a crash
It isn't possible to tell without looking at my_print_func()
One thread will run while others will crash or abort

Answer:
It isn't possible to tell without looking at my_print_func()

Note: This Question is unanswered, help us to find answer for this one