#include <bits/stdc++.h>
using namespace std;
const int MOD = 1e9 + 7;
const int maxn = 1e5 + 5;
const int base = 131;
const int B = 32;
mt19937 rng(chrono::steady_clock::now().time_since_epoch().count());
int RandInt(int l, int r) {
  int random_int = uniform_int_distribution<int>(l, r)(rng);
  return random_int;
}
int a, b, c, d;
int Check(int x) {
  x *= 2;
  int y = sqrt(x);
  if (y * (y + 1) == x) return y + 1;
  return -1;
}
void Solve(int test_case) {
  cin >> a >> b >> c >> d;
  int ones = Check(d);
  int zeros = Check(a);
  if (b == 0 && c == 0) {
    if (a > 0 && d > 0) {
      cout << "Impossible\n";
      return;
    }
    if (a == 0 && d == 0) {
      cout << 0 << "\n";
      return;
    }
    if (a == 0)
      zeros = 0;
    else
      ones = 0;
  }
  if (ones == -1 || zeros == -1) {
    cout << "Impossible\n";
    return;
  }
  long long socap = 1ll * ones * zeros;
  if (socap != b + c) {
    cout << "Impossible\n";
    return;
  }
  int tmp = ones;
  int cur = 0;
  for (int i = 1; i <= ones + zeros; ++i) {
    cur += tmp;
    int res;
    if (cur <= b) {
      res = 0;
    } else {
      cur -= tmp;
      res = 1;
      --tmp;
    }
    cout << res;
  }
}
signed main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  if (fopen(""
            ".inp",
            "r")) {
    freopen(
        ""
        ".inp",
        "r", stdin);
    freopen(
        ""
        ".out",
        "w", stdout);
  }
  int test_case = 1;
  for (int i = 1; i <= test_case; ++i) {
    Solve(i);
  }
  return 0;
}
