#include <bits/stdc++.h>
using namespace std;
#pragma comment(linker, "/STACK:667772160")
template <class T1>
void deb(T1 e1) {
  cout << e1 << endl;
}
template <class T1, class T2>
void deb(T1 e1, T2 e2) {
  cout << e1 << " " << e2 << endl;
}
template <class T1, class T2, class T3>
void deb(T1 e1, T2 e2, T3 e3) {
  cout << e1 << " " << e2 << " " << e3 << endl;
}
template <class T1, class T2, class T3, class T4>
void deb(T1 e1, T2 e2, T3 e3, T4 e4) {
  cout << e1 << " " << e2 << " " << e3 << " " << e4 << endl;
}
template <class T1, class T2, class T3, class T4, class T5>
void deb(T1 e1, T2 e2, T3 e3, T4 e4, T5 e5) {
  cout << e1 << " " << e2 << " " << e3 << " " << e4 << " " << e5 << endl;
}
template <class T1, class T2, class T3, class T4, class T5, class T6>
void deb(T1 e1, T2 e2, T3 e3, T4 e4, T5 e5, T6 e6) {
  cout << e1 << " " << e2 << " " << e3 << " " << e4 << " " << e5 << " " << e6
       << endl;
}
long long cal(long long a) {
  long long ans = 8;
  ans = ans * a + 1;
  long long tp = sqrt(ans);
  if (tp * tp == ans) {
    ans = tp + 1;
    ans = ans / 2LL;
    return ans;
  }
  return -1;
}
int main() {
  long long a, b, c, d, one, zero;
  scanf("%lld %lld", &a, &b);
  scanf("%lld %lld", &c, &d);
  if (a + b + c + d <= 1) {
    if (b + c == 1) {
      if (b == 1)
        deb("01");
      else
        deb(10);
      return 0;
    }
    if (a + d == 0)
      printf("1\n");
    else {
      if (a == 1)
        printf("00\n");
      else
        printf("11\n");
    }
    return 0;
  }
  if (a + b + c == 0 and cal(d) != -1) {
    d = cal(d);
    for (int i = 0; i < d; i++) printf("1");
    printf("\n");
    return 0;
  }
  if (b + c + d == 0 and cal(a) != -1) {
    a = cal(a);
    for (int i = 0; i < a; i++) printf("0");
    printf("\n");
    return 0;
  }
  zero = cal(a);
  one = cal(d);
  bool ok = true;
  if (zero == -1 or one == -1 or zero * one != c + b) {
    printf("Impossible\n");
    return 0;
  }
  a = 0;
  d = 0;
  char str[1000000 + 7];
  int k = 0;
  while (1) {
    if (one == 0) break;
    while (b >= one) {
      str[k] = '0';
      zero--;
      b -= one;
      k++;
      if (k > 1000000) break;
    }
    str[k] = '1';
    one--;
    k++;
    if (k > 1000000) break;
  }
  if (k + zero > 1000000) {
    printf("Impossible\n");
    return 0;
  }
  while (zero) {
    str[k++] = '0';
    zero--;
  }
  for (int i = 0; i < k; i++) printf("%c", str[i]);
  printf("\n");
  return 0;
}

### Prompt

Your challenge is to write a Cpp solution to the following problem:

For each string s consisting of characters '0' and '1' one can define four integers a00, a01, a10 and a11, where axy is the number of subsequences of length 2 of the string s equal to the sequence {x, y}. 

In these problem you are given four integers a00, a01, a10, a11 and have to find any non-empty string s that matches them, or determine that there is no such string. One can prove that if at least one answer exists, there exists an answer of length no more than 1 000 000.

Input

The only line of the input contains four non-negative integers a00, a01, a10 and a11. Each of them doesn't exceed 109.

Output

If there exists a non-empty string that matches four integers from the input, print it in the only line of the output. Otherwise, print "Impossible". The length of your answer must not exceed 1 000 000.

Examples

Input

1 2 3 4


Output

Impossible


Input

1 2 2 1


Output

0110

### Response

```cpp
#include <bits/stdc++.h>
using namespace std;
#pragma comment(linker, "/STACK:667772160")
template <class T1>
void deb(T1 e1) {
  cout << e1 << endl;
}
template <class T1, class T2>
void deb(T1 e1, T2 e2) {
  cout << e1 << " " << e2 << endl;
}
template <class T1, class T2, class T3>
void deb(T1 e1, T2 e2, T3 e3) {
  cout << e1 << " " << e2 << " " << e3 << endl;
}
template <class T1, class T2, class T3, class T4>
void deb(T1 e1, T2 e2, T3 e3, T4 e4) {
  cout << e1 << " " << e2 << " " << e3 << " " << e4 << endl;
}
template <class T1, class T2, class T3, class T4, class T5>
void deb(T1 e1, T2 e2, T3 e3, T4 e4, T5 e5) {
  cout << e1 << " " << e2 << " " << e3 << " " << e4 << " " << e5 << endl;
}
template <class T1, class T2, class T3, class T4, class T5, class T6>
void deb(T1 e1, T2 e2, T3 e3, T4 e4, T5 e5, T6 e6) {
  cout << e1 << " " << e2 << " " << e3 << " " << e4 << " " << e5 << " " << e6
       << endl;
}
long long cal(long long a) {
  long long ans = 8;
  ans = ans * a + 1;
  long long tp = sqrt(ans);
  if (tp * tp == ans) {
    ans = tp + 1;
    ans = ans / 2LL;
    return ans;
  }
  return -1;
}
int main() {
  long long a, b, c, d, one, zero;
  scanf("%lld %lld", &a, &b);
  scanf("%lld %lld", &c, &d);
  if (a + b + c + d <= 1) {
    if (b + c == 1) {
      if (b == 1)
        deb("01");
      else
        deb(10);
      return 0;
    }
    if (a + d == 0)
      printf("1\n");
    else {
      if (a == 1)
        printf("00\n");
      else
        printf("11\n");
    }
    return 0;
  }
  if (a + b + c == 0 and cal(d) != -1) {
    d = cal(d);
    for (int i = 0; i < d; i++) printf("1");
    printf("\n");
    return 0;
  }
  if (b + c + d == 0 and cal(a) != -1) {
    a = cal(a);
    for (int i = 0; i < a; i++) printf("0");
    printf("\n");
    return 0;
  }
  zero = cal(a);
  one = cal(d);
  bool ok = true;
  if (zero == -1 or one == -1 or zero * one != c + b) {
    printf("Impossible\n");
    return 0;
  }
  a = 0;
  d = 0;
  char str[1000000 + 7];
  int k = 0;
  while (1) {
    if (one == 0) break;
    while (b >= one) {
      str[k] = '0';
      zero--;
      b -= one;
      k++;
      if (k > 1000000) break;
    }
    str[k] = '1';
    one--;
    k++;
    if (k > 1000000) break;
  }
  if (k + zero > 1000000) {
    printf("Impossible\n");
    return 0;
  }
  while (zero) {
    str[k++] = '0';
    zero--;
  }
  for (int i = 0; i < k; i++) printf("%c", str[i]);
  printf("\n");
  return 0;
}

```