#include <bits/stdc++.h>
using namespace std;
long long a[2][2], num[2];
string res;
long long num1(int x) {
  long long m = x;
  m <<= 1;
  m = sqrt(m);
  m++;
  return m;
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  ;
  for (int i = 0; i <= 1; i++)
    for (int j = 0; j <= 1; j++) cin >> a[i][j];
  for (int i = 0; i <= 1; i++) num[i] = num1(a[i][i]);
  if (num[0] * (num[0] - 1) / 2 != a[0][0] ||
      num[1] * (num[1] - 1) / 2 != a[1][1]) {
    cout << "Impossible";
    return 0;
  }
  if (num[0] * num[1] != a[1][0] + a[0][1]) {
    bool ok = 0;
    if (a[1][0] + a[0][1] == 0 && (num[1] == 1 || num[0] == 1)) ok = 1;
    if (!ok)
      cout << "Impossible";
    else {
      if (num[0] < num[1])
        num[0] = 0;
      else
        num[1] = 0;
      for (int i = 1; i <= num[0]; i++) cout << "0";
      for (int i = 1; i <= num[1]; i++) cout << "1";
    }
    return 0;
  }
  for (int i = 1; i <= num[0] + num[1]; i++) res += '0';
  for (int i = 0; i <= res.size() - 1; i++)
    if (!num[0] || a[0][1] < num[1]) {
      num[1]--;
      res[i] = '1';
    } else {
      num[0]--;
      a[0][1] -= num[1];
    }
  cout << res;
  return 0;
}
