Diners - implementation
Diners - implementation
for (int i =0; i
stick[i] = new Chopstick();
for (int i =0; i
phil[i] = new Philosopher(stick[(i-1+N)%N],stick[i]);
phil[i].start();
}
Demo
What happens when eating and thinking time is reduced in the
demonstration program?