#include <bits/stdc++.h>
using namespace std;
int l_0, l_1;
long long a00, a01, a10, a11, n0, n1, t, tmp;
char s[1000003];
inline bool judge(long long x, long long &num) {
  tmp = 1 + 8 * x;
  t = sqrt(0.0 + tmp);
  if (t * t != tmp) {
    return false;
  }
  num = (1 + t) >> 1;
  return true;
}
int main() {
  while (4 == scanf("%I64d%I64d%I64d%I64d", &a00, &a01, &a10, &a11)) {
    if (a00 + a01 + a10 + a11 == 0) {
      printf("0\n");
    } else if (!judge(a00, n0) || !judge(a11, n1)) {
      printf("Impossible\n");
    } else if (a00 + a01 + a10 == 0) {
      while (n1 > 0) {
        printf("1");
        --n1;
      }
      printf("\n");
    } else if (a01 + a10 + a11 == 0) {
      while (n0 > 0) {
        printf("0");
        --n0;
      }
      printf("\n");
    } else if (n0 * n1 != a01 + a10) {
      printf("Impossible\n");
    } else {
      l_0 = a01 / n1;
      l_1 = n1 - a01 % n1;
      for (int i = 0; i < l_0; ++i) {
        printf("0");
        --n0;
      }
      for (int i = 0; i < l_1; ++i) {
        printf("1");
        --n1;
      }
      if (n0 > 0) {
        printf("0");
        --n0;
      }
      while (n1 > 0) {
        printf("1");
        --n1;
      }
      while (n0 > 0) {
        printf("0");
        --n0;
      }
      printf("\n");
    }
  }
  return 0;
}
