The first known correct software solution to the critical-section problem for n processes with a lower bound

Question:

The first known correct software solution to the critical-section problem for n processes with a lower bound on waiting of n − 1 turns was presented by Eisenberg and McGuire. The processes share the following variables:
enum pstate {idle, want in, in cs};
pstate flag[n];
int turn;
All the elements of flag are initially idle; the initial value of turn is immaterial (between 0 and n-1). The structure of process Pi is shown in Figure 6.26. Prove that the algorithm satisfies all three requirements for the critical-section problem.
Fantastic news! We've Found the answer you've been seeking!

Step by Step Answer:

Question Posted: