第二题用 srand(time(NULL)); int x = rand()%2; if(x==0) cout<<"YES"<<endl; else if(x==1) cout<<"NO"<<endl; 摇奖摇了个66.67%🤣