#include <bits/stdc++.h>
using namespace std;
int a00, a01, a10, a11;
int gao(int num) {
  num *= 2;
  int t = sqrt(num);
  if (t * (t - 1) == num) return t;
  if (t * (t + 1) == num) return t + 1;
  if ((t - 1) * (t - 2) == num) return t - 1;
  return -1;
}
bool ok(int cnt0, int a01, int a10, int cnt1) {
  if (cnt0 == -1 || cnt1 == -1) return false;
  if (cnt0 == 0 && cnt1 == 0) {
    return false;
  } else if (cnt0 == 0) {
    if (a01 || a10) return false;
    for (int i = 0; i < cnt1; ++i) putchar('1');
    return true;
  } else if (cnt1 == 0) {
    if (a01 || a10) return false;
    for (int i = 0; i < cnt0; ++i) putchar('0');
    return true;
  }
  if (cnt0 == -1 || cnt1 == -1 || cnt0 * cnt1 != a01 + a10) {
    return false;
  }
  int need = a10;
  int num = need / cnt0;
  need = need - cnt0 * num;
  for (int i = 0; i < num; ++i) putchar('1');
  for (int i = 0; i < cnt0 - need; ++i) putchar('0');
  if (cnt1 - num) putchar('1');
  for (int i = 0; i < need; ++i) putchar('0');
  for (int i = 0; i < cnt1 - num - 1; ++i) putchar('1');
  return true;
}
int main() {
  scanf("%d %d %d %d", &a00, &a01, &a10, &a11);
  bool flag = false;
  if (a00 == 0 && a11 == 0) {
    if (!flag) flag = ok(1, a01, a10, 1);
    if (!flag) flag = ok(0, a01, a10, 1);
    if (!flag) flag = ok(1, a01, a10, 0);
  } else if (a00 == 0) {
    if (!flag) flag = ok(1, a01, a10, gao(a11));
    if (!flag) flag = ok(0, a01, a10, gao(a11));
  } else if (a11 == 0) {
    if (!flag) flag = ok(gao(a00), a01, a10, 0);
    if (!flag) flag = ok(gao(a00), a01, a10, 1);
  } else {
    if (!flag) flag = ok(gao(a00), a01, a10, gao(a11));
  }
  if (!flag) puts("Impossible");
  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>
using namespace std;
int a00, a01, a10, a11;
int gao(int num) {
  num *= 2;
  int t = sqrt(num);
  if (t * (t - 1) == num) return t;
  if (t * (t + 1) == num) return t + 1;
  if ((t - 1) * (t - 2) == num) return t - 1;
  return -1;
}
bool ok(int cnt0, int a01, int a10, int cnt1) {
  if (cnt0 == -1 || cnt1 == -1) return false;
  if (cnt0 == 0 && cnt1 == 0) {
    return false;
  } else if (cnt0 == 0) {
    if (a01 || a10) return false;
    for (int i = 0; i < cnt1; ++i) putchar('1');
    return true;
  } else if (cnt1 == 0) {
    if (a01 || a10) return false;
    for (int i = 0; i < cnt0; ++i) putchar('0');
    return true;
  }
  if (cnt0 == -1 || cnt1 == -1 || cnt0 * cnt1 != a01 + a10) {
    return false;
  }
  int need = a10;
  int num = need / cnt0;
  need = need - cnt0 * num;
  for (int i = 0; i < num; ++i) putchar('1');
  for (int i = 0; i < cnt0 - need; ++i) putchar('0');
  if (cnt1 - num) putchar('1');
  for (int i = 0; i < need; ++i) putchar('0');
  for (int i = 0; i < cnt1 - num - 1; ++i) putchar('1');
  return true;
}
int main() {
  scanf("%d %d %d %d", &a00, &a01, &a10, &a11);
  bool flag = false;
  if (a00 == 0 && a11 == 0) {
    if (!flag) flag = ok(1, a01, a10, 1);
    if (!flag) flag = ok(0, a01, a10, 1);
    if (!flag) flag = ok(1, a01, a10, 0);
  } else if (a00 == 0) {
    if (!flag) flag = ok(1, a01, a10, gao(a11));
    if (!flag) flag = ok(0, a01, a10, gao(a11));
  } else if (a11 == 0) {
    if (!flag) flag = ok(gao(a00), a01, a10, 0);
    if (!flag) flag = ok(gao(a00), a01, a10, 1);
  } else {
    if (!flag) flag = ok(gao(a00), a01, a10, gao(a11));
  }
  if (!flag) puts("Impossible");
  return 0;
}

```