#include <bits/stdc++.h>
using namespace std;
long long int a, b, c, d;
long long int bb(long long int a) {
  long long int lo = 1;
  long long int hi = 1e9;
  while (lo < hi) {
    long long int mid = (lo + hi) / 2ll;
    if (mid * (mid - 1ll) < 2ll * a)
      lo = mid + 1ll;
    else
      hi = mid;
  }
  return lo;
}
void fail() {
  printf("Impossible\n");
  exit(0);
}
int main() {
  scanf("%d %d %d %d", &a, &b, &c, &d);
  if (a == 0 && b == 0 && c == 0 && d == 0) {
    printf("0\n");
    return 0;
  }
  long long int f = bb(a);
  long long int t = bb(d);
  if (f * (f - 1ll) != 2ll * a) fail();
  if (t * (t - 1ll) != 2ll * d) fail();
  if (b == 0 && c == 0) {
    if (!a) f = 0;
    if (!d) t = 0;
    if ((f && t) || (!f && !t)) {
      fail();
    }
    while (f--) putchar('0');
    while (t--) putchar('1');
    putchar('\n');
  } else {
    if (f * t != b + c) fail();
    while (f || t) {
      if (t > b) {
        putchar('1');
        t--;
        c -= f;
      } else {
        putchar('0');
        f--;
        b -= t;
      }
    }
    putchar('\n');
  }
}
