模拟题,上网看中文才弄懂题意,不难,记住要设最长循环时间,过了就算输。
#include <iostream>
#include <queue>
using namespace std;
int main(int argc, char const *argv[])
{
int t,n,temp,cnt = 1;
cin >> t;
while(t--)
{
cin >> n;
queue<int>card[11];
int count[11],last[11],throwcard = 0, time = 0;
for(int i = 0; i < 52; i++)
{
cin >> temp;
card[0].push(temp);
}
for(int i = 0; i < n; i++)
c......
阅读全文