Problem: <image>

William is hosting a party for n of his trader friends. They started a discussion on various currencies they trade, but there's an issue: not all of his trader friends like every currency. They like some currencies, but not others.

For each William's friend i it is known whether he likes currency j. There are m currencies in total. It is also known that a trader may not like more than p currencies.

Because friends need to have some common topic for discussions they need to find the largest by cardinality (possibly empty) subset of currencies, such that there are at least ⌈ n/2 ⌉ friends (rounded up) who like each currency in this subset.

Input

The first line contains three integers n, m and p (1 ≤ n ≤ 2 ⋅ 10^5, 1 ≤ p ≤ m ≤ 60, 1 ≤ p ≤ 15), which is the number of trader friends, the number of currencies, the maximum number of currencies each friend can like.

Each of the next n lines contain m characters. The j-th character of i-th line is 1 if friend i likes the currency j and 0 otherwise. It is guaranteed that the number of ones in each line does not exceed p.

Output

Print a string of length m, which defines the subset of currencies of the maximum size, which are liked by at least half of all friends. Currencies belonging to this subset must be signified by the character 1.

If there are multiple answers, print any.

Examples

Input


3 4 3
1000
0110
1001


Output


1000


Input


5 5 4
11001
10101
10010
01110
11011


Output


10001

Note

In the first sample test case only the first currency is liked by at least ⌈ 3/2 ⌉ = 2 friends, therefore it's easy to demonstrate that a better answer cannot be found.

In the second sample test case the answer includes 2 currencies and will be liked by friends 1, 2, and 5. For this test case there are other currencies that are liked by at least half of the friends, but using them we cannot achieve a larger subset size.

Solution (in CPP):

Solution:
/*input
5 5 4
11001
10101
10010
01110
11011

*/
#include <bits/stdc++.h>
#pragma GCC optimize("unroll-loops,no-stack-protector")
using namespace std;
typedef long long ll;
typedef long double ld;
typedef pair<int,int> pii;
typedef pair<ll,ll> pll;
typedef pair<ld,ld> pdd;
#define IOS ios_base::sync_with_stdio(0); cin.tie(0)
#define ALL(a) a.begin(),a.end()
#define SZ(a) ((int)a.size())
#define F first
#define S second
#define REP(i,n) for(ll i=0;i<((ll)n);i++)
#define eb emplace_back
#define pb push_back
#define MP(a,b) make_pair(a,b)
#define SORT_UNIQUE(c) (sort(c.begin(),c.end()), c.resize(distance(c.begin(),unique(c.begin(),c.end()))))
#define GET_POS(c,x) (int)(lower_bound(c.begin(),c.end(),x)-c.begin())
#define EL cout<<'\n'
#define BS(a,x) binary_search(ALL(a),x)
template<typename T1,typename T2>
ostream& operator<<(ostream& out,pair<T1,T2> P){
	out<<'('<<P.F<<','<<P.S<<')';
	return out;
}
template<typename T>
ostream& operator<<(ostream& out,vector<T> V){
	REP(i,SZ(V)) out<<V[i]<<((i!=SZ(V)-1)?" ":"");
	return out;
}
//}}}
const ll maxn=300005;
const ll maxlg=20;
const ll INF64=1e18;
const int INF=0x3f3f3f3f;
const ll MOD=ll(1e9+7);
const ld PI=acos(-1);
const ld eps=1e-9;
//const ll p=880301;
//const ll P=31;

ll mypow(ll a,ll b){
	ll res=1LL;
	while(b){
		if(b&1) res=res*a%MOD;
		a=a*a%MOD;
		b>>=1;
	}
	return res;
}

ll best = 0;

ll a[maxn];

ll dp[1<<15];

int c[maxn];

int main(){
	IOS;
	ll n,m,p;
	cin>>n>>m>>p;
	REP(i,n){
		string s;
		cin>>s;
		REP(j,m){
			if(s[j] == '1'){
				c[j]++;
				a[i] ^= (1LL<<j);
			}
		}
	}
	bool tmp = 0;
	REP(i,m){
		c[i] = (c[i] + c[i] >= n);
		tmp |= c[i];
	}


	int T = 50;

	bool lucky = 0;

	while(T-- > 0){
		ll idx = 880301LL * T % n;
		REP(j,1<<15) dp[j] = 0;
		vector<ll> v;

		bool debug = 0;

		REP(i,m){
			if(a[idx]&(1LL<<i)){
				v.pb(i);
				if(c[i]) debug = 1;
			}
		}
		if(debug) lucky = 1;
		REP(i,n){
			ll num = 0;
			REP(j,SZ(v)){
				if(a[i]&(1LL<<v[j])){
					num ^= (1LL<<j);
				}
			}
			dp[num]++;
		}
		REP(i,SZ(v)){
			REP(l,(1LL<<SZ(v))){
				ll r = l ^ (1LL<<i);
				if(r<l) continue;
				dp[l] += dp[r];
			}
		}
		ll subbest = 0;
		REP(i,(1<<SZ(v))){
			if(dp[i] + dp[i] >= n){
				if(__builtin_popcountll(i) > __builtin_popcountll(subbest)){
					subbest = i;
				}
			}
		}
		if(debug == 1 and __builtin_popcountll(subbest) == 0){
			assert(0);
		}
		if(__builtin_popcountll(subbest) > __builtin_popcountll(best)){
			ll num = 0;
			REP(i,SZ(v)){
				if(subbest&(1LL<<i)){
					num ^= (1LL<<v[i]);
				}
			}
			best = num;
			assert(__builtin_popcountll(subbest) == __builtin_popcountll(num));
		}
	}
	if(tmp) assert(lucky);
	REP(i,m){
		if(best&(1LL<<i)){
			cout<<1;
		}
		else cout<<0;
	}
	cout<<'\n';
	return 0;
}