#include <bits/stdc++.h>
using namespace std;
long long mod(long long a) {
  if (a < 0) {
    a = 0 - a;
    return a;
  }
  return a;
}
int main() {
  long long a00, a01, a10, a11;
  cin >> a00 >> a01 >> a10 >> a11;
  long long zero, one;
  if (a00 != 0) {
    zero = sqrt(2 * a00);
  } else {
    if (a01 == 0 && a10 == 0) {
      zero = -1;
    } else {
      zero = 0;
    }
  }
  if (a11 != 0) {
    one = sqrt(2 * a11);
  } else {
    if (a01 == 0 && a10 == 0) {
      one = -1;
    } else {
      one = 0;
    }
  }
  if (a00 != ((zero * (zero + 1)) / 2)) {
    cout << "Impossible" << endl;
    return 0;
  }
  if (a11 != ((one * (one + 1)) / 2)) {
    cout << "Impossible" << endl;
    return 0;
  }
  one++;
  zero++;
  long long total = one + zero;
  total = total * (total - 1);
  total = total / 2;
  if (total != (a00 + a11 + a01 + a10)) {
    cout << "Impossible" << endl;
    return 0;
  }
  if (total == 0) {
    cout << "0" << endl;
    return 0;
  }
  string v;
  for (;;) {
    if (one == 0 && zero == 0) {
      break;
    }
    if (zero > 0) {
      if (a01 >= one) {
        v.push_back('0');
        zero--;
        a01 = a01 - one;
      } else {
        one--;
        v.push_back('1');
      }
    } else {
      v.push_back('1');
      one--;
    }
  }
  cout << v << endl;
  return 0;
}
