#include <bits/stdc++.h>
using namespace std;
int main() {
  long long ar[5], i, j, k;
  for (int i = 0; i < 4; i++) scanf("%lld", &ar[i]);
  if (ar[0] == 0 && ar[1] == 1 && ar[2] == 0 && ar[3] == 0) {
    printf("01\n");
    return 0;
  }
  if (ar[0] == 0 && ar[1] == 0 && ar[2] == 1 && ar[3] == 0) {
    printf("10\n");
    return 0;
  }
  if (ar[0] == 0 && ar[1] == 0 && ar[2] == 0 && ar[3] == 0) {
    printf("0\n");
    return 0;
  }
  for (i = 1; i <= 1000000; i++)
    if (((i * (i - 1)) / 2) == ar[0]) break;
  if (i == 1000001) {
    printf("Impossible\n");
    return 0;
  }
  long long a = i;
  for (i = 1; i <= 1000000; i++)
    if (((i * (i - 1)) / 2) == ar[3]) break;
  if (i == 1000001) {
    printf("Impossible\n");
    return 0;
  }
  long long b = i;
  if (ar[0] != 0 && ar[1] == 0 && ar[2] == 0 && ar[3] == 0) {
    for (int i = 1; i <= a; i++) printf("0");
    return 0;
  }
  if (ar[0] == 0 && ar[1] == 0 && ar[2] == 0 && ar[3] != 0) {
    for (int i = 1; i <= b; i++) printf("1");
    return 0;
  }
  if (a * b != ar[1] + ar[2]) {
    printf("Impossible\n");
    return 0;
  }
  long long x = ar[1] / a;
  long long y = ar[1] % a;
  long long p = b - x;
  if (y > 0) p--;
  for (int i = 1; i <= p; i++) printf("1");
  for (int i = 1; i <= y; i++) printf("0");
  if (y > 0) printf("1");
  for (int i = 1; i <= a - y; i++) printf("0");
  for (int i = 1; i <= x; i++) printf("1");
  return 0;
}
