#include<bits/stdc++.h>
#include<iostream>
#include<cstring>
#include<cmath>
using namespace std;
const int N = 10010;
int n;
int col;
bool iszero;
vector<int> a;
int main()
{
int x;
cin >> n;
while(cin >> x)a.push_back(x);
for(int i = 0;i<a.size();i++)
{
iszero = iszero ? false :true;
int k = a[i];
for(int j=0;j<k;j++)
{
cout<<(iszero?"0":"1");
if(col==n-1)puts("");
col = (col+1)%n;
}
}
return 0;
}