#include <bits/stdc++.h>
using namespace std;
const int size = 1e6 + 1;
long long int fun(long long int a) {
  long long int l = 0, r = 1e8;
  while (l < r) {
    long long int mid = (l + r) / 2;
    long long int x = mid * (mid - 1);
    x /= 2;
    if (x >= a)
      r = mid;
    else
      l = mid + 1;
  }
  return l;
}
int main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  ;
  long long int a, b, c, d;
  cin >> a >> b >> c >> d;
  long long int n = fun(a);
  long long int m = fun(d);
  string ans = "";
  if (n * (n - 1) != 2 * a or m * (m - 1) != 2 * d) {
    cout << "Impossible";
    return 0;
  }
  if (a == 0 and b == 0 and c == 0 and d == 0) {
    cout << "1";
    return 0;
  }
  if (n == 0 and (b != 0 or c != 0)) n = 1;
  if (m == 0 and (b != 0 or c != 0)) m = 1;
  long long int l, r, mid = 0;
  if (n != 0) {
    r = b / n;
    mid = b % n;
  } else
    r = m;
  l = m - r - (mid != 0);
  if (mid == 0) {
    if ((l * n) != c or l < 0) {
      cout << "Impossible";
      return 0;
    }
    while (l--) ans += "1";
    while (n--) ans += "0";
    while (r--) ans += "1";
  } else {
    if ((l * n + n - mid) != c or l < 0) {
      cout << "Impossible";
      return 0;
    }
    while (l--) ans += "1";
    int x = mid;
    while (x--) ans += "0";
    ans += "1";
    x = n - mid;
    while (x--) ans += "0";
    while (r--) ans += "1";
  }
  cout << ans;
  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;
const int size = 1e6 + 1;
long long int fun(long long int a) {
  long long int l = 0, r = 1e8;
  while (l < r) {
    long long int mid = (l + r) / 2;
    long long int x = mid * (mid - 1);
    x /= 2;
    if (x >= a)
      r = mid;
    else
      l = mid + 1;
  }
  return l;
}
int main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  ;
  long long int a, b, c, d;
  cin >> a >> b >> c >> d;
  long long int n = fun(a);
  long long int m = fun(d);
  string ans = "";
  if (n * (n - 1) != 2 * a or m * (m - 1) != 2 * d) {
    cout << "Impossible";
    return 0;
  }
  if (a == 0 and b == 0 and c == 0 and d == 0) {
    cout << "1";
    return 0;
  }
  if (n == 0 and (b != 0 or c != 0)) n = 1;
  if (m == 0 and (b != 0 or c != 0)) m = 1;
  long long int l, r, mid = 0;
  if (n != 0) {
    r = b / n;
    mid = b % n;
  } else
    r = m;
  l = m - r - (mid != 0);
  if (mid == 0) {
    if ((l * n) != c or l < 0) {
      cout << "Impossible";
      return 0;
    }
    while (l--) ans += "1";
    while (n--) ans += "0";
    while (r--) ans += "1";
  } else {
    if ((l * n + n - mid) != c or l < 0) {
      cout << "Impossible";
      return 0;
    }
    while (l--) ans += "1";
    int x = mid;
    while (x--) ans += "0";
    ans += "1";
    x = n - mid;
    while (x--) ans += "0";
    while (r--) ans += "1";
  }
  cout << ans;
  return 0;
}

```