#include <bits/stdc++.h>
using namespace std;
long long a, b, c, d;
map<long long, long long> choo;
long long zeroes, ones;
string ans;
int32_t main() {
  ios_base::sync_with_stdio(false);
  if (fopen("cf709d.in", "r")) {
    freopen("cf709d.in", "r", stdin);
    freopen("cf709d.out", "w", stdout);
  }
  cin >> a >> b >> c >> d;
  for (long long i = 1; i < 100000; i++) {
    long long x = (i * i - i) / 2;
    choo[x] = i;
  }
  if (choo[a] == 0 || choo[d] == 0 || choo[a + b + c + d] == 0) {
    cout << "Impossible\n";
    return 0;
  }
  if (b == 0 && c == 0 && d == 0) {
    int x = choo[a];
    for (int i = 0; i < x; i++) {
      cout << '0';
    }
    cout << '\n';
    return 0;
  }
  if (a == 0 && b == 0 && c == 0) {
    int x = choo[d];
    for (int i = 0; i < x; i++) {
      cout << '1';
    }
    cout << '\n';
    return 0;
  }
  zeroes = choo[a];
  ones = choo[d];
  if (zeroes + ones != choo[a + b + c + d]) {
    cout << "Impossible\n";
    return 0;
  }
  int len = choo[a + b + c + d];
  for (int i = 0; i < len; i++) {
    if (b >= ones) {
      ans += '0';
      zeroes--;
      b -= ones;
    } else {
      ans += '1';
      ones--;
      c -= zeroes;
    }
  }
  cout << ans << '\n';
  return 0;
}
