#include <bits/stdc++.h>
using namespace std;
long long a00, a01, a10, a11;
long long calc(long long x) {
  if (x == 0) return 1;
  for (long long i = 0; i * (i - 1) / 2 <= x; i++)
    if (i * (i - 1) / 2 == x) return i;
  return -1;
}
signed main() {
  scanf("%lld %lld %lld %lld", &a00, &a01, &a10, &a11);
  if (a00 == 0 && a01 == 0 && a10 == 0 && a11 == 0) {
    puts("0");
    return 0;
  }
  long long a0 = calc(a00), a1 = calc(a11);
  if (a0 == -1 || a1 == -1)
    puts("Impossible");
  else if (a00 + a10 + a01 == 0)
    for (long long i = 1; i <= a1; i++) printf("1");
  else if (a11 + a10 + a01 == 0)
    for (long long i = 1; i <= a0; i++) printf("0");
  else if (a10 + a01 != a1 * a0)
    puts("Impossible");
  else {
    if (a0) {
      long long pre = a10 / a0, cnt = 0;
      a10 %= a0;
      for (long long i = 1; i <= pre; i++, cnt++) printf("1");
      for (long long i = 1; i <= a0 - a10; i++) printf("0");
      if (a1 && a01) printf("1");
      cnt++;
      for (long long i = 1; i <= a10; i++) printf("0");
      if (a01)
        for (long long i = cnt + 1; i <= a1; i++) printf("1");
      puts("");
    } else if (a1) {
      long long pre = a01 / a1, cnt = 0;
      a01 %= a1;
      for (long long i = 1; i <= pre; i++, cnt++) printf("0");
      for (long long i = 1; i <= a1 - a01; i++) printf("1");
      if (a0 && a10) printf("0");
      cnt++;
      for (long long i = 1; i <= a10; i++) printf("1");
      if (a10)
        for (long long i = cnt + 1; i <= a0; i++) printf("0");
      puts("");
    }
  }
}

### 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>
using namespace std;
long long a00, a01, a10, a11;
long long calc(long long x) {
  if (x == 0) return 1;
  for (long long i = 0; i * (i - 1) / 2 <= x; i++)
    if (i * (i - 1) / 2 == x) return i;
  return -1;
}
signed main() {
  scanf("%lld %lld %lld %lld", &a00, &a01, &a10, &a11);
  if (a00 == 0 && a01 == 0 && a10 == 0 && a11 == 0) {
    puts("0");
    return 0;
  }
  long long a0 = calc(a00), a1 = calc(a11);
  if (a0 == -1 || a1 == -1)
    puts("Impossible");
  else if (a00 + a10 + a01 == 0)
    for (long long i = 1; i <= a1; i++) printf("1");
  else if (a11 + a10 + a01 == 0)
    for (long long i = 1; i <= a0; i++) printf("0");
  else if (a10 + a01 != a1 * a0)
    puts("Impossible");
  else {
    if (a0) {
      long long pre = a10 / a0, cnt = 0;
      a10 %= a0;
      for (long long i = 1; i <= pre; i++, cnt++) printf("1");
      for (long long i = 1; i <= a0 - a10; i++) printf("0");
      if (a1 && a01) printf("1");
      cnt++;
      for (long long i = 1; i <= a10; i++) printf("0");
      if (a01)
        for (long long i = cnt + 1; i <= a1; i++) printf("1");
      puts("");
    } else if (a1) {
      long long pre = a01 / a1, cnt = 0;
      a01 %= a1;
      for (long long i = 1; i <= pre; i++, cnt++) printf("0");
      for (long long i = 1; i <= a1 - a01; i++) printf("1");
      if (a0 && a10) printf("0");
      cnt++;
      for (long long i = 1; i <= a10; i++) printf("1");
      if (a10)
        for (long long i = cnt + 1; i <= a0; i++) printf("0");
      puts("");
    }
  }
}

```