#include <bits/stdc++.h>
using namespace std;
long long n, m, a[2][2], b, c, d, x, y, p, q, t, ans, res, ma, mi, T;
void compute(int one, int zero) {
  c = one + zero;
  while (c && zero > 0) {
    while (a[1][0] >= zero) {
      cout << '1';
      c--;
      a[1][0] -= zero;
    }
    cout << '0';
    c--;
    zero--;
  }
  while (c--) cout << '1';
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  for (long long i = 0; i < 2; i++)
    for (long long j = 0; j < 2; j++) {
      cin >> a[i][j];
      if (a[i][j] < 0) ans = -1;
    }
  p = sqrt(1ll + 8 * a[0][0]);
  q = sqrt(1ll + 8 * a[1][1]);
  if (p * p != 1ll + 8 * a[0][0] || q * q != 1ll + 8 * a[1][1]) ans = -1;
  if (p % 2 == 0 || q % 2 == 0) ans = -1;
  long long zero = (1 + sqrt(1ll + 8 * a[0][0])) / 2;
  long long one = (1 + sqrt(1ll + 8 * a[1][1])) / 2;
  if (ans == -1) {
    cout << "Impossible";
    return 0;
  }
  if (a[0][0] == 0 && a[0][1] == 0 && a[1][0] == 0) {
    for (long long i = 0; i < one; i++) cout << '1';
    return 0;
  }
  if (a[1][1] == 0 && a[0][1] == 0 && a[1][0] == 0) {
    for (long long i = 0; i < zero; i++) cout << '0';
    return 0;
  }
  if (!zero && (a[1][0] > 0 || a[0][1] > 0)) ans = -1;
  if (!one && (a[1][0] > 0 || a[0][1] > 0)) ans = -1;
  if (zero != 0 &&
      ((a[0][1] + a[1][0]) % zero != 0 || (a[0][1] + a[1][0]) / zero != one))
    ans = -1;
  if (one != 0 &&
      ((a[0][1] + a[1][0]) % one != 0 || (a[0][1] + a[1][0]) / one != zero))
    ans = -1;
  if (ans == -1) {
    cout << "Impossible";
    return 0;
  }
  compute(one, zero);
  return 0;
}
