Answer:
monitor fileSharer
{
enum {THINKING, WAITING, READING} state[N];
condition self[N];
int total;
void open(int i) {
state[i] = WAITING;
if (i + total >= N)
{ self[i].wait(); } // Leaves monitor
state[i] = READING;
total += i;
}
void close(int i) {
state[i] = THINKING;
total -= i;
// Can signal one waiting proc whose ID won't break bank.
for (int x = N - total - 1; x >= 0; x--) {
if (state[x] == WAITING) {
self[x].signal(); break;
}
}
}
initialization.code() {
for (int i = 0; i < N; i++) {
state[i] = THINKING;
}
total = 0;
}
}
You please post it here first lemme try it at once
Answer:
Document the solution
Explanation:
In the following scenario, we should document the solution in the next troubleshooting strategy because when a user states that the meeting room projector has problems with the monitor when it is attached to his laptop. While finding the following cause and fixing the problem entirely, the projector shows the images correctly on both the laptop and the projector.
So, we should document the solution in our next troubleshooting strategy.
The answer is C hope i helped :)
I believe that you would belong to the ANON group or anonymous users.