#include <bits/stdc++.h>
using namespace std;
const int N = 100000 + 10;
const long long INF = 0x3f3f3f3f3f3f3f3fLL;
int main() {
  long long a, b, c, d, zero = 0, one = 0, pp;
  cin >> a >> b >> c >> d;
  if (!a && !b && !c && !d) {
    printf("0\n");
  } else {
    if (b | c) {
      zero = 1;
      one = 1;
    }
    while (zero * (zero - 1) / 2 < a) zero++;
    while (one * (one - 1) / 2 < d) one++;
    if (zero * (zero - 1) / 2 != a) {
      puts("Impossible");
      return 0;
    }
    if (one * (one - 1) / 2 != d) {
      puts("Impossible");
      return 0;
    }
    pp = zero * one;
    if (pp != (b + c)) {
      puts("Impossible");
      return 0;
    }
    pp = zero + one;
    for (int i = 0; i < pp; i++) {
      if (b - one >= 0) {
        b -= one;
        zero--;
        printf("0");
      } else {
        c -= zero;
        one--;
        printf("1");
      }
    }
  }
}
