#include <cstdio>
#pragma comment(linker, "/STACK:16777216")
const int maxn=5000;
char s1[maxn],s2[maxn],ans[maxn];
int df1[maxn], df2[maxn];
char pr[1024][1024];
void calc_diff(char *s, int *diff, int n){
diff[0]=0;
for(int i=1; i<=n; ++i){
diff[i]= (s[i-1]=='0') ? diff[i-1]+1 : diff[i-1]-1;
}
}
int n;
void dfs(int i, int j){
if(i>=n && j>=n){
return;
}
int diff=df1[i]+df2[j];
if(i<n && !pr[i+1][j] && ( (diff<1 && s1[i]=='0') || (diff>-1 && s1[i]=='1') ) ){
pr[i+1][j]='1';
dfs(i+1, j);
}
if( j<n && !pr[i][j+1] && ( (diff<1 && s2[j]=='0') || (diff>-1 && s2[j]=='1' ) ) ){
pr[i][j+1]='2';
dfs(i, j+1);
}
}
int main()
{
scanf("%d", &n);
scanf("%s", s1);
scanf("%s", s2);
calc_diff(s1, df1, n);
calc_diff(s2, df2, n);
dfs(0, 0);
if(pr[n][n]==0){
printf("Impossible");
return 0;
}
ans[(n<<1)]='\0';
for(int i=(n<<1)-1, a=n, b=n; i>=0; --i){
ans[i]=pr[a][b];
if(ans[i]=='1'){
--a;
}
else{
--b;
}
}
printf("%s", ans);
return 0;
}
I2luY2x1ZGUgPGNzdGRpbz4KCiNwcmFnbWEgY29tbWVudChsaW5rZXIsICIvU1RBQ0s6MTY3NzcyMTYiKQoKY29uc3QgaW50IG1heG49NTAwMDsKCmNoYXIgczFbbWF4bl0sczJbbWF4bl0sYW5zW21heG5dOwppbnQgZGYxW21heG5dLCBkZjJbbWF4bl07CgpjaGFyIHByWzEwMjRdWzEwMjRdOwp2b2lkIGNhbGNfZGlmZihjaGFyICpzLCBpbnQgKmRpZmYsIGludCBuKXsKCiAgICBkaWZmWzBdPTA7CgogICAgZm9yKGludCBpPTE7IGk8PW47ICsraSl7CiAgICAgICAgZGlmZltpXT0gKHNbaS0xXT09JzAnKSA/IGRpZmZbaS0xXSsxIDogZGlmZltpLTFdLTE7CiAgICB9Cgp9CgppbnQgbjsKdm9pZCBkZnMoaW50IGksIGludCBqKXsKICAgIGlmKGk+PW4gJiYgaj49bil7CiAgICAgICAgcmV0dXJuOwogICAgfQoKICAgIGludCBkaWZmPWRmMVtpXStkZjJbal07CgogICAgaWYoaTxuICYmICAgIXByW2krMV1bal0gJiYgKCAgICAoZGlmZjwxICYmIHMxW2ldPT0nMCcpIHx8IChkaWZmPi0xICYmIHMxW2ldPT0nMScpICAgKSAgKXsKICAgICAgICBwcltpKzFdW2pdPScxJzsKICAgICAgICBkZnMoaSsxLCBqKTsKICAgIH0KCiAgICBpZiggICAgajxuICYmICFwcltpXVtqKzFdICYmICggICAgKGRpZmY8MSAmJiBzMltqXT09JzAnKSB8fCAoZGlmZj4tMSAmJiBzMltqXT09JzEnICAgKSAgICkgICApewogICAgICAgIHByW2ldW2orMV09JzInOwogICAgICAgIGRmcyhpLCBqKzEpOwoKICAgIH0KCn0KaW50IG1haW4oKQp7CiAgICBzY2FuZigiJWQiLCAmbik7CgogICAgc2NhbmYoIiVzIiwgczEpOwogICAgc2NhbmYoIiVzIiwgczIpOwoKICAgIGNhbGNfZGlmZihzMSwgZGYxLCBuKTsKICAgIGNhbGNfZGlmZihzMiwgZGYyLCBuKTsKCgoKCiAgICBkZnMoMCwgMCk7CgogICAgaWYocHJbbl1bbl09PTApewogICAgICAgIHByaW50ZigiSW1wb3NzaWJsZSIpOwogICAgICAgIHJldHVybiAwOwogICAgfQoKICAgIGFuc1sobjw8MSldPSdcMCc7CiAgICBmb3IoaW50IGk9KG48PDEpLTEsIGE9biwgYj1uOyBpPj0wOyAtLWkpewogICAgICAgIGFuc1tpXT1wclthXVtiXTsKICAgICAgICBpZihhbnNbaV09PScxJyl7CiAgICAgICAgICAgIC0tYTsKICAgICAgICB9CiAgICAgICAgZWxzZXsKICAgICAgICAgICAgLS1iOwogICAgICAgIH0KICAgIH0KCiAgICBwcmludGYoIiVzIiwgYW5zKTsKICAgIHJldHVybiAwOwp9