求助
查看原帖
求助
941843
Jayant_xincheng楼主2023/6/6 20:35
#include<iostream>
#include<cstring>
#include<cstdio>
#include<cmath>
#include<iomanip>
using namespace std;
int main()
{
	int n,tot=0,o=1;
	cin>>n;
	int y;
	while(cin>>y)
	{
		for(int i=0;i<y;i++)
		{
			if(o%2==0)
			{
				cout<<1;
				tot++;
			}
			else
			{
				cout<<0;
				tot++;
			}
			if(tot%7==0)
			{
				cout<<endl;
			}
		}
		o++;
	}
}

大佬帮一下

2023/6/6 20:35
加载中...