
#include<iostream>
#include<thread>
#include<windows.h>
using namespace std;
int turn;
bool Flag[2] = {
false,false };
void Process_0()
{
Flag[0] = true;
turn = 1;//P0未进入临界区
while ((Flag

#include<iostream>
#include<thread>
#include<windows.h>
using namespace std;
int turn;
bool Flag[2] = {
false,false };
void Process_0()
{
Flag[0] = true;
turn = 1;//P0未进入临界区
while ((Flag
705
292

被折叠的 条评论
为什么被折叠?