#include <bits/stdc++.h>
using namespace std;
int main() {
  long long a, b, c, d;
  scanf("%I64d%I64d%I64d%I64d", &a, &b, &c, &d);
  if (a == 0 && b == 0 && c == 0 && d == 0) {
    printf("0\n");
    return 0;
  }
  double x = sqrt(1 + 8 * a);
  double y = sqrt(1 + 8 * d);
  if (x * x == 1 + 8 * a && y * y == 1 + 8 * d && (long long)x % 2 == 1 &&
      (long long)y % 2 == 1) {
    int zero = (1 + x) / 2;
    int one = (1 + y) / 2;
    int tempZero = zero;
    int tempOne = one;
    int temp = b / one;
    int i = 1;
    if (a == 0 && b == 0 && c == 0 && d != 0) {
      for (int i = 1; i <= one; ++i) printf("1");
      printf("\n");
      return 0;
    }
    if (a != 0 && b == 0 && c == 0 && d == 0) {
      for (int i = 1; i <= zero; ++i) printf("0");
      printf("\n");
      return 0;
    }
    if ((long long)zero * (long long)one != b + c) {
      printf("Impossible\n");
      return 0;
    }
    for (; i <= temp; ++i) {
      printf("0");
      --tempZero;
    }
    if ((c % one) != 0) {
      while (((c % one) != 0)) {
        printf("1");
        c--;
        --tempOne;
      }
    } else {
      do {
        printf("1");
        c--;
        --tempOne;
      } while (((c % one) != 0));
    }
    if (tempZero > 0) {
      printf("0");
      --tempZero;
    }
    while (tempOne > 0) {
      printf("1");
      --tempOne;
    }
    while (tempZero > 0) {
      printf("0");
      tempZero--;
    }
    printf("\n");
  } else
    printf("Impossible\n");
  return 0;
}
