18405075335zbh @ 2023-10-22 15:54:42
#include<iostream>
using namespace std;
int main(){
short int a[40005]={},b;
cin>>b;
for(int i=0,s=0,c,d=1;s<b*b;i++){
cin>>c;
s+=c;
for(int j=d;j<=s;j++){
a[j+1]=i%2;
d=j;
}
}for(int i=1;i<=b;i++){
for(int j=(i-1)*7+1;j<=i*7;j++){
cout<<a[j];
}
cout<<endl;
}
return 0;
}