#include <bits/stdc++.h>
int cnt[1000001];
void end() {
  printf("Impossible\n");
  exit(0);
}
int main() {
  long long i, a, b, c, d, n, m, mm, j;
  scanf("%lld%lld%lld%lld", &a, &b, &c, &d);
  for (i = 1;; i++) {
    if (i * (i - 1) / 2 == a) {
      n = i;
      break;
    }
    if (i * (i - 1) / 2 > a) end();
  }
  for (i = 1;; i++) {
    if (i * (i - 1) / 2 == d) {
      m = i;
      break;
    }
    if (i * (i - 1) / 2 > d) end();
  }
  if (a == 0 && d == 0) {
    if (b == 1 && c == 0)
      printf("01\n");
    else if (b == 0 && c == 1)
      printf("10\n");
    else if (b == 0 && c == 0)
      printf("1\n");
    else
      end();
    return 0;
  } else if (a == 0) {
    if (m * (m - 1) / 2 == a + b + c + d)
      n = 0;
    else if ((m + 1) * m / 2 == a + b + c + d)
      n = 1;
    else
      end();
  } else if (d == 0) {
    if (n * (n - 1) / 2 == a + b + c + d)
      m = 0;
    else if ((n + 1) * n / 2 == a + b + c + d)
      m = 1;
    else
      end();
  } else if ((n + m) * (n + m - 1) / 2 != a + b + c + d)
    end();
  mm = b;
  for (i = 1; i <= m; i++) {
    if (mm >= n) {
      mm -= n;
      cnt[(int)n]++;
    } else if (mm == 0)
      cnt[0]++;
    else {
      cnt[(int)mm]++;
      mm = 0;
    }
  }
  for (i = 1; i <= cnt[0]; i++) printf("1");
  for (i = 1; i <= n; i++) {
    printf("0");
    for (j = 1; j <= cnt[(int)i]; j++) printf("1");
  }
  return 0;
}

### Prompt

Develop a solution in CPP to the problem described below:

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>
int cnt[1000001];
void end() {
  printf("Impossible\n");
  exit(0);
}
int main() {
  long long i, a, b, c, d, n, m, mm, j;
  scanf("%lld%lld%lld%lld", &a, &b, &c, &d);
  for (i = 1;; i++) {
    if (i * (i - 1) / 2 == a) {
      n = i;
      break;
    }
    if (i * (i - 1) / 2 > a) end();
  }
  for (i = 1;; i++) {
    if (i * (i - 1) / 2 == d) {
      m = i;
      break;
    }
    if (i * (i - 1) / 2 > d) end();
  }
  if (a == 0 && d == 0) {
    if (b == 1 && c == 0)
      printf("01\n");
    else if (b == 0 && c == 1)
      printf("10\n");
    else if (b == 0 && c == 0)
      printf("1\n");
    else
      end();
    return 0;
  } else if (a == 0) {
    if (m * (m - 1) / 2 == a + b + c + d)
      n = 0;
    else if ((m + 1) * m / 2 == a + b + c + d)
      n = 1;
    else
      end();
  } else if (d == 0) {
    if (n * (n - 1) / 2 == a + b + c + d)
      m = 0;
    else if ((n + 1) * n / 2 == a + b + c + d)
      m = 1;
    else
      end();
  } else if ((n + m) * (n + m - 1) / 2 != a + b + c + d)
    end();
  mm = b;
  for (i = 1; i <= m; i++) {
    if (mm >= n) {
      mm -= n;
      cnt[(int)n]++;
    } else if (mm == 0)
      cnt[0]++;
    else {
      cnt[(int)mm]++;
      mm = 0;
    }
  }
  for (i = 1; i <= cnt[0]; i++) printf("1");
  for (i = 1; i <= n; i++) {
    printf("0");
    for (j = 1; j <= cnt[(int)i]; j++) printf("1");
  }
  return 0;
}

```