#include <bits/stdc++.h>
using namespace std;
long long a[5], x, y;
int main() {
  cin >> a[1] >> a[2] >> a[3] >> a[4];
  int i;
  x = 1;
  while (x * (x - 1) < 2 * a[1]) x++;
  if (x * (x - 1) > 2 * a[1]) {
    cout << "Impossible\n";
    return 0;
  }
  y = 1;
  while (y * (y - 1) < 2 * a[4]) y++;
  if (y * (y - 1) > 2 * a[4]) {
    cout << "Impossible\n";
    return 0;
  }
  if (a[2] == 0 && a[3] == 0) {
    if (a[1] > 0 && a[4] > 0) {
      cout << "Impossible\n";
      return 0;
    }
    if (a[4] > 0) {
      for (i = 1; i <= y; i++) cout << 1;
    } else
      for (i = 1; i <= x; i++) cout << 0;
    cout << "\n";
    return 0;
  }
  if (a[2] + a[3] != x * y) {
    cout << "Impossible\n";
    return 0;
  }
  int cnt = a[2] / y, r = a[2] % y;
  for (i = 1; i <= cnt; i++) cout << 0;
  for (i = 1; i <= y - r; i++) cout << 1;
  if (cnt < x) cout << 0;
  for (i = 1; i <= r; i++) cout << 1;
  for (i = 1; i <= x - cnt - 1; i++) cout << 0;
  cout << "\n";
  return 0;
}
