求c语言 翻纸牌游戏
求c语言 翻纸牌游戏
日期:2017-09-14 03:39:27 人气:1
#include #include #include #include int main(){ int a, b; int i, p; int oc = 0; int card[6] = { 0,0,0,0,0,0 }; int opened[6] = { 0,0,0,0,0,0 }; srand(time(0)); for (i = 1; i <= 6; i++) { p = rand() % 6; while (card[p]) p = rand() % 6; card[p] = (i +