#include <bits/stdc++.h>
using namespace std;
const double eps = 1e-5;
const int maxlen = 2e6;
string ans;
int main() {
  long long a, b, c, d;
  long long n, m;
  scanf("%I64d%I64d%I64d%I64d", &a, &b, &c, &d);
  long long l, r;
  l = 0;
  r = 1e5;
  while (r - l > 1) {
    n = (r + l) / 2;
    if (n * (n - 1) / 2 <= a)
      l = n;
    else
      r = n;
  }
  n = l;
  l = 0;
  r = 1e5;
  while (r - l > 1) {
    m = (r + l) / 2;
    if (m * (m - 1) / 2 <= d)
      l = m;
    else
      r = m;
  }
  m = l;
  if (a == 0 && b == 0 && c == 0 && d == 0) {
    printf("0");
    return 0;
  }
  if (a == 0 && (b + c) != 0) n = 1;
  if (a == 0 && (b + c) == 0) n = 0;
  if (d == 0 && (b + c) != 0) m = 1;
  if (d == 0 && (b + c) == 0) m = 0;
  ans.resize(n + m);
  for (int i = 0; i < n; ++i) ans[i] = '0';
  for (int i = n; i < n + m; ++i) ans[i] = '1';
  if (n * (n - 1) / 2 != a || m * (m - 1) / 2 != d || n * m != b + c) {
    printf("Impossible\n");
    return 0;
  }
  long long sc = n * m;
  long long i = n;
  long long j = 0;
  while (b < sc) {
    if (b + n <= sc) {
      sc -= n;
      swap(ans[j], ans[i]);
    } else {
      long long k = sc - b;
      swap(ans[i - k], ans[i]);
      sc -= k;
    }
    i++;
    j++;
  }
  cout << ans;
  return 0;
}
