#include <bits/stdc++.h>
using namespace std;
const double eps = 1e-11;
const int maxn = 1e5 + 9;
const double pi = 3.14159265358979323846264;
const int inf = 1e9;
const int mod = 1e9 + 7;
long long op[maxn];
int main() {
  ios::sync_with_stdio(false);
  long long a, b, c, d;
  cin >> a >> b >> c >> d;
  for (long long i = 1; i < maxn; ++i) op[i] = (i - 1) * i / 2;
  int pos;
  if (a) {
    pos = lower_bound(op, op + maxn, a) - op;
    if (op[pos] != a)
      a = -1;
    else
      a = pos;
  } else {
    if (b || c)
      a = 1;
    else
      a = 0;
  }
  if (d) {
    pos = lower_bound(op, op + maxn, d) - op;
    if (op[pos] != d)
      d = -1;
    else
      d = pos;
  } else {
    if (b || c)
      d = 1;
    else
      d = 0;
  }
  if (a < 0 || d < 0 || b + c != a * d) {
    cout << "Impossible";
    return 0;
  }
  if (!a && !d) {
    cout << 0;
    return 0;
  } else if (!a) {
    for (int i = 0; i < d; ++i) cout << 1;
    return 0;
  } else if (!d) {
    for (int i = 0; i < a; ++i) cout << 0;
    return 0;
  }
  long long tb = b / a, mb = b % a;
  long long tc = c / a, mc = c % a;
  for (int i = 0; i < tc; ++i) cout << 1;
  if (mb) {
    for (int i = 0; i < mb; ++i) cout << 0;
    cout << 1;
    for (int i = mb; i < a; ++i) cout << 0;
  } else {
    for (int i = 0; i < a; ++i) cout << 0;
  }
  for (int i = 0; i < tb; ++i) cout << 1;
  return 0;
}

### Prompt

Please create a solution in cpp 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 double eps = 1e-11;
const int maxn = 1e5 + 9;
const double pi = 3.14159265358979323846264;
const int inf = 1e9;
const int mod = 1e9 + 7;
long long op[maxn];
int main() {
  ios::sync_with_stdio(false);
  long long a, b, c, d;
  cin >> a >> b >> c >> d;
  for (long long i = 1; i < maxn; ++i) op[i] = (i - 1) * i / 2;
  int pos;
  if (a) {
    pos = lower_bound(op, op + maxn, a) - op;
    if (op[pos] != a)
      a = -1;
    else
      a = pos;
  } else {
    if (b || c)
      a = 1;
    else
      a = 0;
  }
  if (d) {
    pos = lower_bound(op, op + maxn, d) - op;
    if (op[pos] != d)
      d = -1;
    else
      d = pos;
  } else {
    if (b || c)
      d = 1;
    else
      d = 0;
  }
  if (a < 0 || d < 0 || b + c != a * d) {
    cout << "Impossible";
    return 0;
  }
  if (!a && !d) {
    cout << 0;
    return 0;
  } else if (!a) {
    for (int i = 0; i < d; ++i) cout << 1;
    return 0;
  } else if (!d) {
    for (int i = 0; i < a; ++i) cout << 0;
    return 0;
  }
  long long tb = b / a, mb = b % a;
  long long tc = c / a, mc = c % a;
  for (int i = 0; i < tc; ++i) cout << 1;
  if (mb) {
    for (int i = 0; i < mb; ++i) cout << 0;
    cout << 1;
    for (int i = mb; i < a; ++i) cout << 0;
  } else {
    for (int i = 0; i < a; ++i) cout << 0;
  }
  for (int i = 0; i < tb; ++i) cout << 1;
  return 0;
}

```