#include <bits/stdc++.h>
using namespace std;
long long deTri(long long in) {
  long long out = 1;
  while (in > 0) {
    in -= out;
    out++;
  }
  if (in == 0) {
    return out;
  } else {
    return -1;
  }
}
void printZero(int in) {
  for (int i = 0; i < in; i++) {
    printf("0");
  }
}
void printOne(int in) {
  for (int i = 0; i < in; i++) {
    printf("1");
  }
}
int main() {
  long long a, b, c, d;
  scanf("%I64d %I64d %I64d %I64d", &a, &b, &c, &d);
  long long zeroes, ones;
  if (b == 0 && c == 0) {
    if (a == 0 && d == 0) {
      printf("0");
    } else if (a > 0 && d == 0) {
      zeroes = deTri(a);
      if (zeroes == -1) {
        printf("Impossible");
      } else {
        printZero(zeroes);
      }
    } else if (a == 0) {
      ones = deTri(d);
      if (ones == -1) {
        printf("Impossible");
      } else {
        printOne(ones);
      }
    } else {
      printf("Impossible");
    }
  } else {
    zeroes = deTri(a);
    ones = deTri(d);
    if (zeroes == -1 || ones == -1) {
      printf("Impossible");
    } else if (zeroes * ones != b + c) {
      printf("Impossible");
    } else if (b == 0) {
      printOne(ones);
      printZero(zeroes);
    } else if (c == 0) {
      printZero(zeroes);
      printOne(ones);
    } else {
      int startZ = 0, endZ = 0;
      while (b >= 0) {
        b -= ones;
        startZ++;
      }
      startZ--;
      b += ones;
      while (c >= 0) {
        c -= ones;
        endZ++;
      }
      endZ--;
      c += ones;
      if (b + c == 0) {
        printZero(startZ);
        printOne(ones);
        printZero(endZ);
      } else {
        printZero(startZ);
        printOne(c);
        printZero(1);
        printOne(b);
        printZero(endZ);
      }
    }
  }
  scanf("%d", &a);
}
