#include <bits/stdc++.h>
using namespace std;
const int maxn = 1000000 + 23;
const double eps = 1e-6;
long long num[4][4], num0, num1;
int size, a[maxn];
bool check() {
  if ((num[0][0] > 0) || (num[0][1] > 0) || (num[1][0] > 0) || (num[1][1] > 0))
    return true;
  return false;
}
int main() {
  scanf("%I64d%I64d%I64d%I64d", &num[0][0], &num[0][1], &num[1][0], &num[1][1]);
  if (num[0][0] > 0)
    num0 = ((long long)(sqrt(num[0][0] * 8 + 1 + eps)) + 1) / 2;
  else if ((num[0][1] > 0) || (num[1][0] > 0))
    num0 = 1;
  else
    num0 = 0;
  if (num[1][1] > 0)
    num1 = ((long long)(sqrt(num[1][1] * 8 + 1 + eps)) + 1) / 2;
  else if ((num[1][0] > 0) || (num[0][1] > 0))
    num1 = 1;
  else
    num1 = 0;
  if (((num0 * (num0 - 1)) / 2 != num[0][0]) ||
      (((num1 - 1) * num1) / 2 != num[1][1])) {
    printf("Impossible\n");
    return 0;
  }
  size = 0;
  while (check()) {
    size++;
    a[size] = -1;
    if ((num0 == 0) && (num1 == 0) && (check())) break;
    if ((num1 <= num[0][1]) && (num0 <= (num[0][0] + 1))) {
      a[size] = 0, num[0][1] -= num1, num[0][0] -= (num0 - 1), num0--;
      continue;
    }
    if ((num0 <= num[1][0]) && (num1 <= (num[1][1] + 1))) {
      a[size] = 1, num[1][0] -= num0, num[1][1] -= (num1 - 1), num1--;
      continue;
    }
    if (a[size] == -1) break;
  }
  if (a[size] == -1) {
    printf("Impossible\n");
    return 0;
  }
  if ((num0 > 1) || (num1 > 1) || ((num0 > 0) && (num1 > 0))) {
    printf("Impossible\n");
    return 0;
  }
  if (num0)
    a[++size] = 0;
  else
    a[++size] = 1;
  for (int i = 1; i <= size; i++) printf("%d", a[i]);
  printf("\n");
  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 maxn = 1000000 + 23;
const double eps = 1e-6;
long long num[4][4], num0, num1;
int size, a[maxn];
bool check() {
  if ((num[0][0] > 0) || (num[0][1] > 0) || (num[1][0] > 0) || (num[1][1] > 0))
    return true;
  return false;
}
int main() {
  scanf("%I64d%I64d%I64d%I64d", &num[0][0], &num[0][1], &num[1][0], &num[1][1]);
  if (num[0][0] > 0)
    num0 = ((long long)(sqrt(num[0][0] * 8 + 1 + eps)) + 1) / 2;
  else if ((num[0][1] > 0) || (num[1][0] > 0))
    num0 = 1;
  else
    num0 = 0;
  if (num[1][1] > 0)
    num1 = ((long long)(sqrt(num[1][1] * 8 + 1 + eps)) + 1) / 2;
  else if ((num[1][0] > 0) || (num[0][1] > 0))
    num1 = 1;
  else
    num1 = 0;
  if (((num0 * (num0 - 1)) / 2 != num[0][0]) ||
      (((num1 - 1) * num1) / 2 != num[1][1])) {
    printf("Impossible\n");
    return 0;
  }
  size = 0;
  while (check()) {
    size++;
    a[size] = -1;
    if ((num0 == 0) && (num1 == 0) && (check())) break;
    if ((num1 <= num[0][1]) && (num0 <= (num[0][0] + 1))) {
      a[size] = 0, num[0][1] -= num1, num[0][0] -= (num0 - 1), num0--;
      continue;
    }
    if ((num0 <= num[1][0]) && (num1 <= (num[1][1] + 1))) {
      a[size] = 1, num[1][0] -= num0, num[1][1] -= (num1 - 1), num1--;
      continue;
    }
    if (a[size] == -1) break;
  }
  if (a[size] == -1) {
    printf("Impossible\n");
    return 0;
  }
  if ((num0 > 1) || (num1 > 1) || ((num0 > 0) && (num1 > 0))) {
    printf("Impossible\n");
    return 0;
  }
  if (num0)
    a[++size] = 0;
  else
    a[++size] = 1;
  for (int i = 1; i <= size; i++) printf("%d", a[i]);
  printf("\n");
  return 0;
}

```